Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/make Make it clearer that this is not a memory leak.
details: https://anonhg.NetBSD.org/src/rev/b469497eca89
branches: trunk
changeset: 352989:b469497eca89
user: riastradh <riastradh%NetBSD.org@localhost>
date: Sun Apr 16 21:35:08 2017 +0000
description:
Make it clearer that this is not a memory leak.
CID 978369
diffstat:
usr.bin/make/parse.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diffs (47 lines):
diff -r ab99008e94f1 -r b469497eca89 usr.bin/make/parse.c
--- a/usr.bin/make/parse.c Sun Apr 16 21:23:43 2017 +0000
+++ b/usr.bin/make/parse.c Sun Apr 16 21:35:08 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: parse.c,v 1.221 2017/04/16 21:03:13 riastradh Exp $ */
+/* $NetBSD: parse.c,v 1.222 2017/04/16 21:35:08 riastradh Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
*/
#ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: parse.c,v 1.221 2017/04/16 21:03:13 riastradh Exp $";
+static char rcsid[] = "$NetBSD: parse.c,v 1.222 2017/04/16 21:35:08 riastradh Exp $";
#else
#include <sys/cdefs.h>
#ifndef lint
#if 0
static char sccsid[] = "@(#)parse.c 8.3 (Berkeley) 3/19/94";
#else
-__RCSID("$NetBSD: parse.c,v 1.221 2017/04/16 21:03:13 riastradh Exp $");
+__RCSID("$NetBSD: parse.c,v 1.222 2017/04/16 21:35:08 riastradh Exp $");
#endif
#endif /* not lint */
#endif
@@ -1678,10 +1678,12 @@
}
if (paths) {
Lst_Destroy(paths, NULL);
+ paths = NULL;
}
if (specType == ExPath)
Dir_SetPATH();
} else {
+ assert(paths == NULL);
while (*line) {
/*
* The targets take real sources, so we must beware of archive
@@ -1740,6 +1742,7 @@
}
out:
+ assert(paths == NULL);
if (curTargs)
Lst_Destroy(curTargs, NULL);
}
Home |
Main Index |
Thread Index |
Old Index