X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;f=lib%2Frealloc.c;h=6d6b0baf2304b933602f33db7e24cd2ff7a6b033;hb=fe0f4bf35b9378854a8a709d6067800495d3e845;hp=78c6b19b9cfa204178b5c797a397f4fb825a9446;hpb=ac9212c1d03bd23f6322bef39a4a0384b5afcc5d;p=libucw.git diff --git a/lib/realloc.c b/lib/realloc.c index 78c6b19b..6d6b0baf 100644 --- a/lib/realloc.c +++ b/lib/realloc.c @@ -1,19 +1,26 @@ /* - * Sherlock Library -- Memory Re-allocation + * UCW Library -- Memory Re-allocation * - * (c) 1997 Martin Mares, + * (c) 1997 Martin Mares + * + * This software may be freely distributed and used according to the terms + * of the GNU Lesser General Public License. */ -#include +#include "lib/lib.h" + #include -#include "lib.h" +#ifndef DEBUG_DMALLOC void * xrealloc(void *old, uns size) { + /* We assume that realloc(NULL, x) works like malloc(x), which is true with the glibc. */ void *x = realloc(old, size); if (!x) die("Cannot reallocate %d bytes of memory", size); return x; } + +#endif