ack/lang/basic/lib/salloc.c
1994-06-24 11:31:16 +00:00

21 lines
230 B
C

/* $Id$ */
extern char *malloc() ;
char * salloc(length)
unsigned length;
{
char *c, *s;
c= malloc(length);
if( !c ) error(5);
for(s=c;s<c+length;s++) *s = 0;
return(c);
}
sfree(c)
char *c;
{
if( !c ) return;
free(c);
}