PipeWire  0.3.66
src/pipewire/utils.h File Reference

pipewire/utils.h More...

Go to the source code of this file.

Macros

#define strndupa(s, n)
 
#define strdupa(s)
 
#define pw_rand32()   ({ uint32_t val; pw_random(&val, sizeof(val)); val; })
 
#define PW_DEPRECATED(v)   ({ __typeof__(v) _v SPA_DEPRECATED = (v); (void)_v; (v); })
 

Typedefs

typedef void(* pw_destroy_t) (void *object)
 a function to destroy an item More...
 

Functions

const char * pw_split_walk (const char *str, const char *delimiter, size_t *len, const char **state)
 Split a string based on delimiters. More...
 
char ** pw_split_strv (const char *str, const char *delimiter, int max_tokens, int *n_tokens)
 Split a string based on delimiters. More...
 
int pw_split_ip (char *str, const char *delimiter, int max_tokens, char *tokens[])
 Split a string in-place based on delimiters. More...
 
void pw_free_strv (char **str)
 Free a NULL terminated array of strings. More...
 
char * pw_strip (char *str, const char *whitespace)
 Strip all whitespace before and after a string. More...
 
SPA_WARN_UNUSED_RESULT ssize_t pw_getrandom (void *buf, size_t buflen, unsigned int flags)
 Fill a buffer with random data. More...
 
void pw_random (void *buf, size_t buflen)
 Fill a buffer with random data. More...
 
void * pw_reallocarray (void *ptr, size_t nmemb, size_t size)
 

Detailed Description