/* myalloc.c * last revised at 1, Feb. 1994 * * Copyright (C) 1994, All rights reserved. * written by Gyudong Kim(chilly@eleceng.adelaide.edu.au) * */ #include "findhier.h" void freelink(parent) struct names **parent; { struct names *tmp,*save; for(tmp=(*parent);tmp!=NULL;) { save = tmp->next; myfree(tmp); tmp = save; } (*parent) = (struct names *)NULL; } void *myalloc(size,caller) SIZE size; char *caller; { void *tmp; tmp = (void *)malloc(size); if (tmp==NULL) { warning("Memory Exhausted in %s.\n",caller); exit(-1); } return(tmp); } /* myalloc.c */