summaryrefslogtreecommitdiff
path: root/commands.c
diff options
context:
space:
mode:
authorRoland McGrath <roland@redhat.com>1992-04-21 07:50:13 +0000
committerRoland McGrath <roland@redhat.com>1992-04-21 07:50:13 +0000
commit02b78d7ed07108fe1f7a7f3cc8323ccb78ee6f30 (patch)
tree14077b5e997fbd2b1e8bbc5c80e9205d7aea145d /commands.c
parent3fcefefce50e59ba420e34040ceb71a7d374fd83 (diff)
downloadgunmake-02b78d7ed07108fe1f7a7f3cc8323ccb78ee6f30.tar.gz
Formerly commands.c.~3~
Diffstat (limited to 'commands.c')
-rw-r--r--commands.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/commands.c b/commands.c
index 94097e2..31f43ad 100644
--- a/commands.c
+++ b/commands.c
@@ -367,11 +367,9 @@ fatal_error_signal (sig)
if (sig == SIGTERM)
{
register struct child *c;
- push_signals_blocked_p (1);
for (c = children; c != 0; c = c->next)
if (!c->remote)
(void) kill (c->pid, SIGTERM);
- pop_signals_blocked_p ();
}
/* If we got a signal that means the user
@@ -380,7 +378,6 @@ fatal_error_signal (sig)
if (PROPAGATED_SIGNAL_MASK & sigmask (sig))
{
register struct child *c;
- push_signals_blocked_p (1);
/* Remote children won't automatically get signals sent
to the process group, so we must send them. */
@@ -391,15 +388,15 @@ fatal_error_signal (sig)
for (c = children; c != 0; c = c->next)
delete_child_targets (c);
- pop_signals_blocked_p ();
-
/* Clean up the children. We don't just use the call below because
we don't want to print the "Waiting for children" message. */
- wait_for_children (0, 0);
+ while (job_slots_used > 0)
+ reap_children (1, 0);
}
else
/* Wait for our children to die. */
- wait_for_children (0, 1);
+ while (job_slots_used > 0)
+ reap_children (1, 1);
/* Delete any non-precious intermediate files that were made. */