Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: job-control
- X-seq: zsh-workers 9503
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx
- Subject: Re: PATCH: job-control
- Date: Tue, 1 Feb 2000 11:58:27 +0100 (MET)
- In-reply-to: Sven Wischnowsky's message of Mon, 31 Jan 2000 13:53:36 +0100 (MET)
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
I wrote:
> But removing those two child_* and
> adding:
>
> if (list_pipe_job && jobtab[list_pipe_job].procs &&
> !(jobtab[list_pipe_job].stat & STAT_STOPPED))
> child_suspend(0);
>
> before the if (!list_pipe_child && ...) fixes the problem, too and is
> almost certainly better. Can anyone see a problem with this?
No, we would also need a child_block, then, so we can use
child_unblock()/child_block() after this test.
I haven't found an example where this fails...
Bye
Sven
diff -ru ../z.old/Src/exec.c Src/exec.c
--- ../z.old/Src/exec.c Tue Feb 1 11:33:24 2000
+++ Src/exec.c Tue Feb 1 11:34:43 2000
@@ -980,9 +980,12 @@
jn->stat |= STAT_NOPRINT;
makerunning(jn);
}
- if (!(jn->stat & STAT_LOCKED)) {
- child_unblock();
+ if (!(jn->stat & STAT_LOCKED))
waitjobs();
+
+ if (list_pipe_job && jobtab[list_pipe_job].procs &&
+ !(jobtab[list_pipe_job].stat & STAT_STOPPED)) {
+ child_unblock();
child_block();
}
if (list_pipe_child &&
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author