]> git.deb.at Git - pkg/abook.git/blobdiff - xmalloc.h
- add xstrdup to have proper checking for memory allocation failures
[pkg/abook.git] / xmalloc.h
index 61ea5b5c69df1e6720093961dacfe77b1dc6bec3..9b0f6de03098c5f18cfd2225ac15c18f87d589da 100644 (file)
--- a/xmalloc.h
+++ b/xmalloc.h
@@ -16,6 +16,7 @@ void *                xmalloc0(size_t);
 void *         xmalloc_inc(size_t, size_t);
 void *         xrealloc(void *, size_t);
 void *         xrealloc_inc(void *, size_t, size_t);
+char *         xstrdup(const char *s);
 
 #define xfree(ptr)     do { free(ptr); ptr = NULL; } while(0)