diff options
Diffstat (limited to 'util.c')
-rw-r--r-- | util.c | 18 |
1 files changed, 0 insertions, 18 deletions
@@ -29,16 +29,6 @@ emalloc(unsigned int size) | |||
29 | return res; | 29 | return res; |
30 | } | 30 | } |
31 | 31 | ||
32 | void * | ||
33 | emallocz(unsigned int size) | ||
34 | { | ||
35 | void *res = calloc(1, size); | ||
36 | |||
37 | if(!res) | ||
38 | bad_malloc(size); | ||
39 | return res; | ||
40 | } | ||
41 | |||
42 | void | 32 | void |
43 | eprint(const char *errstr, ...) | 33 | eprint(const char *errstr, ...) |
44 | { | 34 | { |
@@ -58,11 +48,3 @@ estrdup(const char *str) | |||
58 | bad_malloc(strlen(str)); | 48 | bad_malloc(strlen(str)); |
59 | return res; | 49 | return res; |
60 | } | 50 | } |
61 | |||
62 | void | ||
63 | swap(void **p1, void **p2) | ||
64 | { | ||
65 | void *tmp = *p1; | ||
66 | *p1 = *p2; | ||
67 | *p2 = tmp; | ||
68 | } | ||