diff options
Diffstat (limited to 'util.c')
-rw-r--r-- | util.c | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -40,6 +40,15 @@ eprint(const char *errstr, ...) exit(EXIT_FAILURE); } +void * +erealloc(void *ptr, unsigned int size) +{ + void *res = realloc(ptr, size); + if(!res) + bad_malloc(size); + return res; +} + void spawn(Arg *arg) { |