]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Avoid conflicts with libraries defining their own xmalloc by defining
authorMartin Mares <mj@ucw.cz>
Wed, 29 Mar 2000 22:57:46 +0000 (22:57 +0000)
committerMartin Mares <mj@ucw.cz>
Wed, 29 Mar 2000 22:57:46 +0000 (22:57 +0000)
xmalloc to bird_xmalloc internally.

lib/resource.h

index 1a9939780abe9d09b009e9075e02b6f7faaf9f50..1491fde7ca3d86055601058ff22b0e0194e136a2 100644 (file)
@@ -80,6 +80,12 @@ void sl_free(slab *, void *);
 #define xmalloc(size) _xmalloc_leap(__FILE__, __LINE__, size)
 #define xfree(ptr) _xfree_leap(__FILE__, __LINE__, ptr)
 #else
+/*
+ * Unfortunately, several libraries we might want to link to define
+ * their own xmalloc and we don't want to interfere with them, hence
+ * the renaming.
+ */
+#define xmalloc bird_xmalloc
 void *xmalloc(unsigned);
 #define xfree(x) free(x)
 #endif