summaryrefslogtreecommitdiffstats
path: root/usr.bin/make/make.c
diff options
context:
space:
mode:
authorharti <harti@FreeBSD.org>2005-05-24 16:05:51 +0000
committerharti <harti@FreeBSD.org>2005-05-24 16:05:51 +0000
commitdd5f450e83a2cf110049be4a3dec342b25032631 (patch)
tree7377d4a139d673efd4f875e108415e496df43d39 /usr.bin/make/make.c
parent79613308dce9cef12aa10cea972360bae9c444f3 (diff)
downloadFreeBSD-src-dd5f450e83a2cf110049be4a3dec342b25032631.zip
FreeBSD-src-dd5f450e83a2cf110049be4a3dec342b25032631.tar.gz
The caller of Var_Value() should not change the variable value. Make
this clear by constifying the return value. Obtained from: DragonFlyBSD
Diffstat (limited to 'usr.bin/make/make.c')
-rw-r--r--usr.bin/make/make.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/usr.bin/make/make.c b/usr.bin/make/make.c
index 8a460f1..9a39a9e 100644
--- a/usr.bin/make/make.c
+++ b/usr.bin/make/make.c
@@ -338,10 +338,10 @@ Make_HandleUse(GNode *cgn, GNode *pgn)
void
Make_Update(GNode *cgn)
{
- GNode *pgn; /* the parent node */
- char *cname; /* the child's name */
- LstNode *ln; /* Element in parents and iParents lists */
- char *cpref;
+ GNode *pgn; /* the parent node */
+ const char *cname; /* the child's name */
+ LstNode *ln; /* Element in parents and iParents lists */
+ const char *cpref;
cname = Var_Value(TARGET, cgn);
@@ -491,9 +491,9 @@ Make_Update(GNode *cgn)
void
Make_DoAllVar(GNode *gn)
{
- LstNode *ln;
- GNode *cgn;
- char *child;
+ LstNode *ln;
+ GNode *cgn;
+ const char *child;
LST_FOREACH(ln, &gn->children) {
/*
OpenPOWER on IntegriCloud