Module Name: src
Committed By: rillig
Date: Sat Jan 23 12:35:22 UTC 2021
Modified Files:
src/usr.bin/make: suff.c
Log Message:
make(1): rename local variable in FindCmds
To generate a diff of this commit:
cvs rdiff -u -r1.338 -r1.339 src/usr.bin/make/suff.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/usr.bin/make/suff.c
diff -u src/usr.bin/make/suff.c:1.338 src/usr.bin/make/suff.c:1.339
--- src/usr.bin/make/suff.c:1.338 Sat Jan 23 12:25:35 2021
+++ src/usr.bin/make/suff.c Sat Jan 23 12:35:22 2021
@@ -1,4 +1,4 @@
-/* $NetBSD: suff.c,v 1.338 2021/01/23 12:25:35 rillig Exp $ */
+/* $NetBSD: suff.c,v 1.339 2021/01/23 12:35:22 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -114,7 +114,7 @@
#include "dir.h"
/* "@(#)suff.c 8.4 (Berkeley) 3/21/94" */
-MAKE_RCSID("$NetBSD: suff.c,v 1.338 2021/01/23 12:25:35 rillig Exp $");
+MAKE_RCSID("$NetBSD: suff.c,v 1.339 2021/01/23 12:35:22 rillig Exp $");
typedef List SuffixList;
typedef ListNode SuffixListNode;
@@ -1183,7 +1183,7 @@ FindCmds(Candidate *targ, CandidateSearc
prefLen = strlen(targ->prefix);
for (gln = tgn->children.first; gln != NULL; gln = gln->next) {
- const char *cp;
+ const char *base;
sgn = gln->datum;
@@ -1198,11 +1198,11 @@ FindCmds(Candidate *targ, CandidateSearc
continue;
}
- cp = str_basename(sgn->name);
- if (strncmp(cp, targ->prefix, prefLen) != 0)
+ base = str_basename(sgn->name);
+ if (strncmp(base, targ->prefix, prefLen) != 0)
continue;
/* The node matches the prefix, see if it has a known suffix. */
- suff = FindSuffixByName(cp + prefLen);
+ suff = FindSuffixByName(base + prefLen);
if (suff == NULL)
continue;