summaryrefslogtreecommitdiff
path: root/rule.c
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>1999-06-14 06:50:28 +0000
committerPaul Smith <psmith@gnu.org>1999-06-14 06:50:28 +0000
commit2858f7a8f11990a8b9391e70ab4cdaa271522ece (patch)
tree51c2ec242b3725d7c92689b2277244b3691466c8 /rule.c
parent187787286d9bc2f41696090917f47d9935651ddf (diff)
downloadmake-2858f7a8f11990a8b9391e70ab4cdaa271522ece.tar.gz
* Various bug fixes.
Diffstat (limited to 'rule.c')
-rw-r--r--rule.c44
1 files changed, 23 insertions, 21 deletions
diff --git a/rule.c b/rule.c
index 2099e3c..08ab640 100644
--- a/rule.c
+++ b/rule.c
@@ -334,27 +334,29 @@ new_pattern_rule (rule, override)
if (!streq (dep_name (d), dep_name (d2)))
break;
if (d == 0 && d2 == 0)
- /* All the dependencies matched. */
- if (override)
- {
- /* Remove the old rule. */
- freerule (r, lastrule);
- /* Install the new one. */
- if (pattern_rules == 0)
- pattern_rules = rule;
- else
- last_pattern_rule->next = rule;
- last_pattern_rule = rule;
-
- /* We got one. Stop looking. */
- goto matched;
- }
- else
- {
- /* The old rule stays intact. Destroy the new one. */
- freerule (rule, (struct rule *) 0);
- return 0;
- }
+ {
+ /* All the dependencies matched. */
+ if (override)
+ {
+ /* Remove the old rule. */
+ freerule (r, lastrule);
+ /* Install the new one. */
+ if (pattern_rules == 0)
+ pattern_rules = rule;
+ else
+ last_pattern_rule->next = rule;
+ last_pattern_rule = rule;
+
+ /* We got one. Stop looking. */
+ goto matched;
+ }
+ else
+ {
+ /* The old rule stays intact. Destroy the new one. */
+ freerule (rule, (struct rule *) 0);
+ return 0;
+ }
+ }
}
}