summaryrefslogtreecommitdiffstats
path: root/usr.bin/make
diff options
context:
space:
mode:
authorharti <harti@FreeBSD.org>2005-05-10 14:23:31 +0000
committerharti <harti@FreeBSD.org>2005-05-10 14:23:31 +0000
commita07412476954cd3e2b3d73359b473f62c6cf06db (patch)
tree7cee8bfe8fbdc7a8ddf7b51fa81dfd8f1e010536 /usr.bin/make
parent0703a0423457df2d6faca51f4d4a00226b1ad7c5 (diff)
downloadFreeBSD-src-a07412476954cd3e2b3d73359b473f62c6cf06db.zip
FreeBSD-src-a07412476954cd3e2b3d73359b473f62c6cf06db.tar.gz
Path_Expand() expects its first argument to be writeable so put the
default system directory into a writeable character array before passing it to Path_Expand(). Submitted by: Max Okumoto <okumoto@ucsd.edu> (7.210)
Diffstat (limited to 'usr.bin/make')
-rw-r--r--usr.bin/make/main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.bin/make/main.c b/usr.bin/make/main.c
index 1229b20..77be9f4 100644
--- a/usr.bin/make/main.c
+++ b/usr.bin/make/main.c
@@ -862,8 +862,9 @@ main(int argc, char **argv)
/* Path of sys.mk */
Lst sysMkPath = Lst_Initializer(sysMkPath);
LstNode *ln;
+ char defsysmk[] = PATH_DEFSYSMK;
- Path_Expand(PATH_DEFSYSMK, &sysIncPath, &sysMkPath);
+ Path_Expand(defsysmk, &sysIncPath, &sysMkPath);
if (Lst_IsEmpty(&sysMkPath))
Fatal("make: no system rules (%s).", PATH_DEFSYSMK);
LST_FOREACH(ln, &sysMkPath) {
OpenPOWER on IntegriCloud