summaryrefslogtreecommitdiff
path: root/implicit.c
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>1999-07-21 05:53:23 +0000
committerPaul Smith <psmith@gnu.org>1999-07-21 05:53:23 +0000
commit588da9812e055fbceb900c350ab406f97eccbf37 (patch)
treecc291944695d7e922ac93c5ae293289349acd7d5 /implicit.c
parent73846549f62b832ca6ff761ad3640a86d3b32c86 (diff)
downloadgunmake-588da9812e055fbceb900c350ab406f97eccbf37.tar.gz
* Add configure option to enable dmalloc library.
* Various code cleanups.
Diffstat (limited to 'implicit.c')
-rw-r--r--implicit.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/implicit.c b/implicit.c
index 3ed23a3..91b6b98 100644
--- a/implicit.c
+++ b/implicit.c
@@ -247,11 +247,11 @@ pattern_search (file, archive, depth, recursions)
if (check_lastslash)
{
if (stem > (lastslash + 1)
- && strncmp (target, lastslash + 1, stem - lastslash - 1))
+ && !strneq (target, lastslash + 1, stem - lastslash - 1))
continue;
}
else if (stem > filename
- && strncmp (target, filename, stem - filename))
+ && !strneq (target, filename, stem - filename))
continue;
/* Check that the rule pattern matches the text after the stem.
@@ -400,7 +400,7 @@ pattern_search (file, archive, depth, recursions)
&& (((fp = lookup_file (p)) != 0 && !fp->intermediate)
|| file_exists_p (p)))
{
- found_files[deps_found++] = savestring (p, strlen (p));
+ found_files[deps_found++] = xstrdup (p);
continue;
}
/* This code, given FILENAME = "lib/foo.o", dependency name
@@ -432,7 +432,7 @@ pattern_search (file, archive, depth, recursions)
if (pattern_search (intermediate_file, 0, depth + 1,
recursions + 1))
{
- p = savestring (p, strlen (p));
+ p = xstrdup (p);
intermediate_patterns[deps_found]
= intermediate_file->name;
intermediate_file->name = p;
@@ -441,7 +441,7 @@ pattern_search (file, archive, depth, recursions)
/* Allocate an extra copy to go in FOUND_FILES,
because every elt of FOUND_FILES is consumed
or freed later. */
- found_files[deps_found] = savestring (p, strlen (p));
+ found_files[deps_found] = xstrdup (p);
++deps_found;
continue;
}