Mercurial > hg > index.cgi
diff lwlink/util.c @ 2:7317fbe024af
Clean up insane number of compiler warnings under -Wall
author | lost@l-w.ca |
---|---|
date | Thu, 20 Jan 2011 22:39:46 -0700 |
parents | 2c24602be78f |
children |
line wrap: on
line diff
--- a/lwlink/util.c Wed Jan 19 22:31:00 2011 -0700 +++ b/lwlink/util.c Thu Jan 20 22:39:46 2011 -0700 @@ -51,7 +51,7 @@ if (size == 0) { lw_free(optr); - return; + return NULL; } ptr = realloc(optr, size); @@ -60,6 +60,7 @@ fprintf(stderr, "lw_realloc(): memory allocation error\n"); exit(1); } + return ptr; } void lw_free(void *ptr)