summaryrefslogtreecommitdiffstats
path: root/usr.bin/make/suff.c
diff options
context:
space:
mode:
authorharti <harti@FreeBSD.org>2004-12-08 16:28:53 +0000
committerharti <harti@FreeBSD.org>2004-12-08 16:28:53 +0000
commitdebc54781641b995b46b1fc3c2049772e2f6c276 (patch)
treed7a98c1a68b66aa638b825a9bd039225968c92c6 /usr.bin/make/suff.c
parentbcb1f1f6f57e4630d36245b7c5fb2ce234218041 (diff)
downloadFreeBSD-src-debc54781641b995b46b1fc3c2049772e2f6c276.zip
FreeBSD-src-debc54781641b995b46b1fc3c2049772e2f6c276.tar.gz
Don't free the second list in Lst_Concat for LST_CONCLINK; free it
in the caller instead.
Diffstat (limited to 'usr.bin/make/suff.c')
-rw-r--r--usr.bin/make/suff.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/usr.bin/make/suff.c b/usr.bin/make/suff.c
index 4802f2b..b08bc10 100644
--- a/usr.bin/make/suff.c
+++ b/usr.bin/make/suff.c
@@ -454,6 +454,7 @@ Suff_ClearSuffixes(void)
{
Lst_Concat(suffClean, sufflist, LST_CONCLINK);
+ free(sufflist);
sufflist = Lst_Init();
sNum = 1;
suffNull = emptySuff;
@@ -2079,6 +2080,8 @@ sfnd_return:
Lst_Concat(slst, srcs, LST_CONCLINK);
Lst_Concat(slst, targs, LST_CONCLINK);
+ free(srcs);
+ free(targs);
}
/*-
OpenPOWER on IntegriCloud