dhcpd-pools  2.28
ISC dhcpd lease usage analyser
Macros | Functions
xalloc.h File Reference
#include <stddef.h>
#include "xalloc-oversized.h"
Include dependency graph for xalloc.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define XALLOC_INLINE   _GL_INLINE
 
#define _GL_ATTRIBUTE_MALLOC
 
#define _GL_ATTRIBUTE_ALLOC_SIZE(args)
 
#define XMALLOC(t)   ((t *) xmalloc (sizeof (t)))
 
#define XNMALLOC(n, t)   ((t *) (sizeof (t) == 1 ? xmalloc (n) : xnmalloc (n, sizeof (t))))
 
#define XZALLOC(t)   ((t *) xzalloc (sizeof (t)))
 
#define XCALLOC(n, t)   ((t *) (sizeof (t) == 1 ? xzalloc (n) : xcalloc (n, sizeof (t))))
 

Functions

_Noreturn void xalloc_die (void)
 
void * xmalloc (size_t s) _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_ALLOC_SIZE((1))
 
void * xzalloc (size_t s) _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_ALLOC_SIZE((1))
 
void * xcalloc (size_t n, size_t s) _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_ALLOC_SIZE((1
 
void void * xrealloc (void *p, size_t s) _GL_ATTRIBUTE_ALLOC_SIZE((2))
 
void * x2realloc (void *p, size_t *pn)
 
void * xmemdup (void const *p, size_t s) _GL_ATTRIBUTE_ALLOC_SIZE((2))
 
char * xstrdup (char const *str) _GL_ATTRIBUTE_MALLOC
 
XALLOC_INLINE void * xnmalloc (size_t n, size_t s) _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_ALLOC_SIZE((1
 
XALLOC_INLINE void * xnrealloc (void *p, size_t n, size_t s) _GL_ATTRIBUTE_ALLOC_SIZE((2
 
XALLOC_INLINE void * x2nrealloc (void *p, size_t *pn, size_t s)
 
XALLOC_INLINE char * xcharalloc (size_t n) _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_ALLOC_SIZE((1))
 

Macro Definition Documentation

#define _GL_ATTRIBUTE_ALLOC_SIZE (   args)

Referenced by x2nrealloc().

#define _GL_ATTRIBUTE_MALLOC
#define XALLOC_INLINE   _GL_INLINE

Referenced by x2nrealloc().

#define XCALLOC (   n,
 
)    ((t *) (sizeof (t) == 1 ? xzalloc (n) : xcalloc (n, sizeof (t))))
#define XMALLOC (   t)    ((t *) xmalloc (sizeof (t)))
#define XNMALLOC (   n,
 
)    ((t *) (sizeof (t) == 1 ? xmalloc (n) : xnmalloc (n, sizeof (t))))

Referenced by xcharalloc().

#define XZALLOC (   t)    ((t *) xzalloc (sizeof (t)))

Function Documentation

XALLOC_INLINE void* x2nrealloc ( void *  p,
size_t *  pn,
size_t  s 
)

Referenced by x2realloc().

Here is the call graph for this function:

void* x2realloc ( void *  p,
size_t *  pn 
)

Here is the call graph for this function:

_Noreturn void xalloc_die ( void  )

Referenced by quotearg_n_options(), x2nrealloc(), xcalloc(), xmalloc(), xnmalloc(), xnrealloc(), and xrealloc().

Here is the call graph for this function:

void* xcalloc ( size_t  n,
size_t  s 
)

Referenced by main().

XALLOC_INLINE char * xcharalloc ( size_t  n)
void* xmalloc ( size_t  s)

Referenced by add_lease_v4(), add_lease_v6(), main(), parse_config(), parse_leases(), prepare_memory(), xmemdup(), xnmalloc(), and xzalloc().

Here is the call graph for this function:

void* xmemdup ( void const *  p,
size_t  s 
)

Referenced by clone_quoting_options(), and xstrdup().

Here is the call graph for this function:

XALLOC_INLINE void XALLOC_INLINE void * xnmalloc ( size_t  n,
size_t  s 
)

Here is the call graph for this function:

XALLOC_INLINE void XALLOC_INLINE void * xnrealloc ( void *  p,
size_t  n,
size_t  s 
)

Here is the call graph for this function:

void void* xrealloc ( void *  p,
size_t  s 
)

Referenced by parse_config(), quotearg_n_options(), x2nrealloc(), and xnrealloc().

Here is the call graph for this function:

char* xstrdup ( char const *  str)

Referenced by parse_config(), parse_leases(), and prepare_memory().

Here is the call graph for this function:

void* xzalloc ( size_t  s)

Here is the call graph for this function: