home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The C Users' Group Library 1994 August
/
wc-cdrom-cusersgrouplibrary-1994-08.iso
/
listings
/
v_09_02
/
9n02098c
< prev
next >
Wrap
Text File
|
1990-12-13
|
248b
|
19 lines
SYMBOL *savesym(SYMBOL *s)
{
int size;
SYMBOL *p;
size = sizeof(SYMBOL) + strlen(s->symbol);
#ifdef LHEAP
p = sbrk(size);
if(p == (void *)(-1)) return(NULL);
#else
p = malloc(size);
#endif
if(p) memcpy(p,s,size);
return(p);
}