summaryrefslogtreecommitdiff
path: root/bin/ksh/table.c
diff options
context:
space:
mode:
Diffstat (limited to 'bin/ksh/table.c')
-rw-r--r--bin/ksh/table.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/bin/ksh/table.c b/bin/ksh/table.c
index a390c172c77..91b33bc96c5 100644
--- a/bin/ksh/table.c
+++ b/bin/ksh/table.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: table.c,v 1.4 1997/06/19 13:58:47 kstailey Exp $ */
+/* $OpenBSD: table.c,v 1.5 1999/01/10 17:55:03 millert Exp $ */
/*
* dynamic hashed associative table for commands and variables
@@ -55,7 +55,7 @@ texpand(tp, nsize)
if (otblp == NULL)
return;
for (i = 0; i < osize; i++)
- if ((tblp = otblp[i]) != NULL)
+ if ((tblp = otblp[i]) != NULL) {
if ((tblp->flag&DEFINED)) {
for (p = &ntblp[hash(tblp->name)
& (tp->size-1)];
@@ -67,6 +67,7 @@ texpand(tp, nsize)
} else if (!(tblp->flag & FINUSE)) {
afree((void*)tblp, tp->areap);
}
+ }
afree((void*)otblp, tp->areap);
}