mirror of
https://github.com/mirror/make.git
synced 2025-03-29 13:31:09 +08:00
Formerly job.c.~102~
This commit is contained in:
parent
29de1a7e5a
commit
9596950898
32
job.c
32
job.c
@ -333,12 +333,24 @@ reap_children (block, err)
|
|||||||
/* If there are more commands to run, try to start them. */
|
/* If there are more commands to run, try to start them. */
|
||||||
if (job_next_command (c))
|
if (job_next_command (c))
|
||||||
{
|
{
|
||||||
/* Check again whether to start remotely.
|
if (handling_fatal_signal)
|
||||||
Whether or not we want to changes over time.
|
{
|
||||||
Also, start_remote_job may need state set up
|
/* Never start new commands while we are dying.
|
||||||
by start_remote_job_p. */
|
Since there are more commands that wanted to be run,
|
||||||
c->remote = start_remote_job_p ();
|
the target was not completely remade. So we treat
|
||||||
start_job_command (c);
|
this as if a command had failed. */
|
||||||
|
c->file->command_state = cs_finished;
|
||||||
|
c->file->update_status = 1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
/* Check again whether to start remotely.
|
||||||
|
Whether or not we want to changes over time.
|
||||||
|
Also, start_remote_job may need state set up
|
||||||
|
by start_remote_job_p. */
|
||||||
|
c->remote = start_remote_job_p ();
|
||||||
|
start_job_command (c);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (c->file->command_state)
|
switch (c->file->command_state)
|
||||||
@ -362,8 +374,9 @@ reap_children (block, err)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Notice if the target of the commands has been changed. */
|
if (! handling_fatal_signal)
|
||||||
notice_finished_file (c->file);
|
/* Notice if the target of the commands has been changed. */
|
||||||
|
notice_finished_file (c->file);
|
||||||
|
|
||||||
if (debug_flag)
|
if (debug_flag)
|
||||||
printf ("Removing child 0x%08lx PID %d%s from chain.\n",
|
printf ("Removing child 0x%08lx PID %d%s from chain.\n",
|
||||||
@ -375,7 +388,8 @@ reap_children (block, err)
|
|||||||
children = c->next;
|
children = c->next;
|
||||||
else
|
else
|
||||||
lastc->next = c->next;
|
lastc->next = c->next;
|
||||||
free_child (c);
|
if (! handling_fatal_signal) /* Avoid nonreentrancy. */
|
||||||
|
free_child (c);
|
||||||
|
|
||||||
/* There is now another slot open. */
|
/* There is now another slot open. */
|
||||||
--job_slots_used;
|
--job_slots_used;
|
||||||
|
Loading…
Reference in New Issue
Block a user