summaryrefslogtreecommitdiffstats
path: root/lib/memory.h
diff options
context:
space:
mode:
authorChris Hall (GMCH) <chris.hall@highwayman.com>2009-12-10 21:40:17 +0000
committerChris Hall (GMCH) <chris.hall@highwayman.com>2009-12-10 21:40:17 +0000
commit122e52d3c6f844aceddf1b3b35885d0feae6650a (patch)
treec2a5a03b3b39f4adfbc472b2c2a8d9c8fd4dd444 /lib/memory.h
parent2c2397059d4d4177ed4636c08aa476a138425dc8 (diff)
parent16899228d96d10853ff46cac2e24ab311b44e574 (diff)
downloadquagga-122e52d3c6f844aceddf1b3b35885d0feae6650a.tar.bz2
quagga-122e52d3c6f844aceddf1b3b35885d0feae6650a.tar.xz
Merge branch 'master' of /git/quagga.euro-ix
Diffstat (limited to 'lib/memory.h')
-rw-r--r--lib/memory.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/memory.h b/lib/memory.h
index 42eb5cae..037efef2 100644
--- a/lib/memory.h
+++ b/lib/memory.h
@@ -32,7 +32,7 @@ struct mlist {
struct memory_list *list;
const char *name;
};
-
+
#include "lib/memtypes.h"
extern struct mlist mlists[];
@@ -60,6 +60,8 @@ extern struct mlist mlists[];
#define XSTRDUP(mtype, str) zstrdup ((mtype), (str))
#endif /* MEMORY_LOG */
+#define SIZE(t,n) (sizeof(t) * (n))
+
/* Prototypes of memory function. */
extern void *zmalloc (int type, size_t size);
extern void *zcalloc (int type, size_t size);
@@ -69,7 +71,7 @@ extern char *zstrdup (int type, const char *str);
extern void *mtype_zmalloc (const char *file, int line, int type, size_t size);
-extern void *mtype_zcalloc (const char *file, int line, int type,
+extern void *mtype_zcalloc (const char *file, int line, int type,
size_t num, size_t size);
extern void *mtype_zrealloc (const char *file, int line, int type, void *ptr,