comparison utils.h @ 38:b156910b59b2

Wrap free() in dofree() to allow instrumenting it for debugging.
author David A. Holland
date Sat, 30 Mar 2013 21:02:25 -0400
parents 76c114899f63
children 337110e7240a
comparison
equal deleted inserted replaced
37:70902cac4170 38:b156910b59b2
39 extern const char alnum[]; 39 extern const char alnum[];
40 40
41 41
42 void *domalloc(size_t len); 42 void *domalloc(size_t len);
43 void *dorealloc(void *ptr, size_t len); 43 void *dorealloc(void *ptr, size_t len);
44 void dofree(void *ptr);
44 45
45 char *dostrdup(const char *s); 46 char *dostrdup(const char *s);
46 char *dostrdup2(const char *s, const char *t); 47 char *dostrdup2(const char *s, const char *t);
47 char *dostrdup3(const char *s, const char *t, const char *u); 48 char *dostrdup3(const char *s, const char *t, const char *u);
48 char *dostrndup(const char *s, size_t len); 49 char *dostrndup(const char *s, size_t len);