made more ANSI conformant

This commit is contained in:
ceriel 1989-08-09 16:25:50 +00:00
parent be3597ddbe
commit 8279a37642

View file

@ -39,6 +39,9 @@ malloc(n)
register mallink *ml;
register int min_class;
if (n == 0) {
return 0;
}
if (n < MIN_SIZE) n = align(MIN_SIZE); else n = align(n);
#ifdef STORE
if (n <= MAX_STORE*MIN_SIZE) {
@ -234,6 +237,10 @@ realloc(addr, n)
*/
return malloc(n);
}
if (n == 0) {
free(addr);
return 0;
}
ml = mallink_of_block(addr);
if (n < MIN_SIZE) n = align(MIN_SIZE); else n = align(n);
#ifdef STORE