libwget-xalloc - Man Page
Memory allocation functions
Synopsis
Variables
wget_malloc_function * wget_malloc_fn = malloc
wget_calloc_function * wget_calloc_fn = calloc
wget_realloc_function * wget_realloc_fn = realloc
wget_free_function * wget_free = free
WGETAPI wget_malloc_function * wget_malloc_fn
WGETAPI wget_calloc_function * wget_calloc_fn
WGETAPI wget_realloc_function * wget_realloc_fn
WGETAPI wget_free_function * wget_free
RETURNS_NONNULL LIBWGET_WARN_UNUSED_RESULT size_t size
#define wget_xfree(a) do { if (a) { wget_free((void *)(a)); a=NULL; } } while (0)
typedef void * wget_malloc_function(size_t)
Type of malloc() function.
typedef void * wget_calloc_function(size_t, size_t)
Type of calloc() function.
typedef void * wget_realloc_function(void *, size_t)
Type of realloc() function.
typedef void wget_free_function(void *)
Type of free() function.
RETURNS_NONNULL LIBWGET_WARN_UNUSED_RESULT WGET_GCC_ALLOC_SIZE (1) WGET_GCC_MALLOC static inline void *NULLABLE wget_malloc(size_t size)
RETURNS_NONNULL LIBWGET_WARN_UNUSED_RESULT WGET_GCC_ALLOC_SIZE2 (1, 2) WGET_GCC_MALLOC static inline void *NULLABLE wget_calloc(size_t nmemb
RETURNS_NONNULL LIBWGET_WARN_UNUSED_RESULT WGET_GCC_ALLOC_SIZE (2) static inline void *NULLABLE wget_realloc(void *ptr
Detailed Description
Global function pointers to memory allocation functions and to free().
These pointers can be set to custom functions.
Macro Definition Documentation
#define wget_xfree( a) do { if (a) { wget_free((void *)(a)); a=NULL; } } while (0)
Memory allocation function pointers
Variable Documentation
RETURNS_NONNULL LIBWGET_WARN_UNUSED_RESULT size_t size
Initial value:
{ return wget_calloc_fn(nmemb, size)
Author
Generated automatically by Doxygen for wget2 from the source code.