util-linux/mount/xmalloc.h

15 lines
394 B
C
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#ifndef MOUNT_XMALLOC_H
#define MOUNT_XMALLOC_H
extern void *xmalloc(size_t size);
extern void *xrealloc(void *p, size_t size);
extern char *xstrdup(const char *s);
/*
* free(p); when 'p' is 'const char *' makes gcc unhappy:
* warning: passing argument 1 of free discards qualifiers from pointer target type
*/
#define my_free(_p) free((void *) _p)
#endif /* MOUNT_XMALLOC_H */