summaryrefslogtreecommitdiff
path: root/read.c
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>2009-09-27 02:15:36 +0000
committerPaul Smith <psmith@gnu.org>2009-09-27 02:15:36 +0000
commit8688ef20cf5d541e7ca98919cc2d757fbfe1dd32 (patch)
treee78361ae6cb8cd6391c58ce7f3828ac5162f150a /read.c
parent44ac2cdb4dc8481cff33101f95f94761c5aa74bc (diff)
downloadgunmake-8688ef20cf5d541e7ca98919cc2d757fbfe1dd32.tar.gz
- Add static pattern targets to the string cache.
- Use specific free_*() calls where appropriate.
Diffstat (limited to 'read.c')
-rw-r--r--read.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/read.c b/read.c
index 55b26e8..2eb98fa 100644
--- a/read.c
+++ b/read.c
@@ -852,7 +852,7 @@ eval (struct ebuffer *ebuf, int set_default)
const char *name = files->name;
int r;
- free (files);
+ free_ns (files);
files = next;
r = eval_makefile (name,
@@ -1142,7 +1142,7 @@ eval (struct ebuffer *ebuf, int set_default)
{
struct nameseq *target;
target = PARSE_FILE_SEQ (&p2, struct nameseq, ':', NULL,
- PARSEFS_NOGLOB|PARSEFS_NOCACHE);
+ PARSEFS_NOGLOB);
++p2;
if (target == 0)
fatal (fstart, _("missing target pattern"));
@@ -1152,7 +1152,7 @@ eval (struct ebuffer *ebuf, int set_default)
pattern = target->name;
if (pattern_percent == 0)
fatal (fstart, _("target pattern contains no `%%'"));
- free (target);
+ free_ns (target);
}
else
pattern = 0;
@@ -1779,7 +1779,7 @@ record_target_var (struct nameseq *filenames, char *defn,
struct pattern_var *p;
nextf = filenames->next;
- free (filenames);
+ free_ns (filenames);
/* If it's a pattern target, then add it to the pattern-specific
variable list. */
@@ -1938,7 +1938,7 @@ record_files (struct nameseq *filenames, const char *pattern,
/* Count the targets to create an array of target names.
We already have the first one. */
nextf = filenames->next;
- free (filenames);
+ free_ns (filenames);
filenames = nextf;
for (c = 1; nextf; ++c, nextf = nextf->next)
@@ -1963,7 +1963,7 @@ record_files (struct nameseq *filenames, const char *pattern,
++c;
nextf = filenames->next;
- free (filenames);
+ free_ns (filenames);
filenames = nextf;
}
@@ -1981,7 +1981,7 @@ record_files (struct nameseq *filenames, const char *pattern,
struct file *f;
struct dep *this = 0;
- free (filenames);
+ free_ns (filenames);
/* Check for special targets. Do it here instead of, say, snap_deps()
so that we can immediately use the value. */