diff options
author | Paul Smith <psmith@gnu.org> | 2013-07-21 17:52:13 -0400 |
---|---|---|
committer | Paul Smith <psmith@gnu.org> | 2013-07-21 17:52:13 -0400 |
commit | 87ac68fe79a2e3b0d149135d40d8cbc5500024af (patch) | |
tree | 78ca3b513d6d7e662117fc824c40f2db2b521b85 /read.c | |
parent | 72462ef1e181fc99837ba3077f9b5d192f16f6aa (diff) | |
download | gunmake-87ac68fe79a2e3b0d149135d40d8cbc5500024af.tar.gz |
[Bug #39158] Source cleanups suggested by cppcheck utility.
Diffstat (limited to 'read.c')
-rw-r--r-- | read.c | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -1297,14 +1297,13 @@ eval (struct ebuffer *ebuf, int set_default) if (set_default && default_goal_var->value[0] == '\0') { - const char *name; struct dep *d; struct nameseq *t = filenames; for (; t != 0; t = t->next) { int reject = 0; - name = t->name; + const char *name = t->name; /* We have nothing to do if this is an implicit rule. */ if (strchr (name, '%') != 0) @@ -2981,7 +2980,6 @@ parse_file_seq (char **stringp, unsigned int size, int stopmap, /* tmp points to tmpbuf after the prefix, if any. tp is the end of the buffer. */ static char *tmpbuf = NULL; - static int tmpbuf_len = 0; int cachep = NONE_SET (flags, PARSEFS_NOCACHE); @@ -3009,6 +3007,7 @@ parse_file_seq (char **stringp, unsigned int size, int stopmap, /* Get enough temporary space to construct the largest possible target. */ { + static int tmpbuf_len = 0; int l = strlen (*stringp) + 1; if (l > tmpbuf_len) { |