--- ray/src/common/bmalloc.c 2003/02/25 02:47:21 2.4 +++ ray/src/common/bmalloc.c 2003/11/14 17:22:06 2.6 @@ -1,5 +1,5 @@ #ifndef lint -static const char RCSid[] = "$Id: bmalloc.c,v 2.4 2003/02/25 02:47:21 greg Exp $"; +static const char RCSid[] = "$Id: bmalloc.c,v 2.6 2003/11/14 17:22:06 schorsch Exp $"; #endif /* * Bmalloc provides basic memory allocation without overhead (no free lists). @@ -15,6 +15,8 @@ static const char RCSid[] = "$Id: bmalloc.c,v 2.4 2003 #include +#include "rtmisc.h" + #ifndef MBLKSIZ #define MBLKSIZ 16376 /* size of memory allocation block */ #endif @@ -29,8 +31,9 @@ static unsigned int nremain = 0; char * -bmalloc(n) /* allocate a block of n bytes */ -register unsigned int n; +bmalloc( /* allocate a block of n bytes */ +register unsigned int n +) { if (n > nremain && (n > MBLKSIZ || nremain > MBLKSIZ/WASTEFRAC)) return(malloc(n)); /* too big */ @@ -48,9 +51,10 @@ register unsigned int n; void -bfree(p, n) /* free random memory */ -register char *p; -register unsigned int n; +bfree( /* free random memory */ +register char *p, +register unsigned int n +) { register unsigned int bsiz; /* check alignment */