Oops. Missing NULL frees.

This commit is contained in:
Ben Laurie 1999-01-17 14:19:31 +00:00
parent 512d222830
commit f9e6fac357
2 changed files with 6 additions and 0 deletions

View File

@ -176,6 +176,9 @@ LHASH *lh;
unsigned int i;
LHASH_NODE *n,*nn;
if(lh == NULL)
return;
for (i=0; i<lh->num_nodes; i++)
{
n=lh->b[i];

View File

@ -219,6 +219,9 @@ static int free_type;
static void names_lh_free(onp,type)
OBJ_NAME *onp;
{
if(onp == NULL)
return;
if ((free_type < 0) || (free_type == onp->type))
{
OBJ_NAME_remove(onp->name,onp->type);