summaryrefslogtreecommitdiff
path: root/remake.c
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>2011-09-18 20:52:13 +0000
committerPaul Smith <psmith@gnu.org>2011-09-18 20:52:13 +0000
commit6c7ca244ae9b50f66b9994cda82712c65e2a7dc8 (patch)
tree7da506b5572599eff91c1cb67bc1118d3defc885 /remake.c
parent6cacfcb6a698c0b18089a17140c65270980843ab (diff)
downloadmake-6c7ca244ae9b50f66b9994cda82712c65e2a7dc8.tar.gz
We compute various values for vpath lookup the first time through
and store them in static variables; however one value (std_dirs) was not being stored statically so the second time through it was not set. Fixes Savannah bug #32511
Diffstat (limited to 'remake.c')
-rw-r--r--remake.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/remake.c b/remake.c
index 669eadc8..55266243 100644
--- a/remake.c
+++ b/remake.c
@@ -1538,8 +1538,7 @@ library_search (const char *lib, FILE_TIMESTAMP *mtime_ptr)
unsigned int liblen;
/* Information about the earliest (in the vpath sequence) match. */
- unsigned int best_vpath, best_path;
- unsigned int std_dirs = 0;
+ unsigned int best_vpath = 0, best_path = 0;
char **dp;
@@ -1558,6 +1557,7 @@ library_search (const char *lib, FILE_TIMESTAMP *mtime_ptr)
static char *buf = NULL;
static unsigned int buflen = 0;
static int libdir_maxlen = -1;
+ static unsigned int std_dirs = 0;
char *libbuf = variable_expand ("");
/* Expand the pattern using LIB as a replacement. */