zsh-workers
 help / color / mirror / code / Atom feed
From: Mathias Fredriksson <mafredri@gmail.com>
To: zsh-workers@zsh.org
Subject: Re: zsh 5.1 freezes with zombie child
Date: Wed, 2 Sep 2015 09:00:12 +0300	[thread overview]
Message-ID: <CA+=GgY4-V9-yn7-q0b3UaaS4q8ji-AR3tMFPPZ1Fs=fv94oVUQ@mail.gmail.com> (raw)
In-Reply-To: <150901191441.ZM15728@torch.brasslantern.com>

[-- Attachment #1: Type: text/plain, Size: 1192 bytes --]

I'm currently away, but I'll give it a try when I get back at the end of
the week.
On Sep 2, 2015 5:15 AM, "Bart Schaefer" <schaefer@brasslantern.com> wrote:

> On Sep 2,  2:13am, Vincent Lefevre wrote:
> }
> } zira% updprompt() { true && { : } }
> } zira% TRAPCHLD() { updprompt }
> } zira% sleep 2 & sleep 3 ; echo OK
> } [1] 20452
> } [1]  + done       sleep 2
> }
> } and zsh freezes here.
>
> The following fixes it, but makes me nervous.  Is Mathias Fredriksson
> still listening?  Try to reproduce that deadlock from the thread back
> at the beginning of August?  (Was it really that recently?  Gaah.)
>
>
> diff --git a/Src/signals.c b/Src/signals.c
> index f45c186..aa0b5aa 100644
> --- a/Src/signals.c
> +++ b/Src/signals.c
> @@ -1348,6 +1348,7 @@ void
>  dotrap(int sig)
>  {
>      void *funcprog;
> +    int q = queue_signal_level();
>
>      if (sigtrapped[sig] & ZSIG_FUNC) {
>         HashNode hn = gettrapnode(sig, 0);
> @@ -1370,5 +1371,9 @@ dotrap(int sig)
>      if ((sigtrapped[sig] & ZSIG_IGNORED) || !funcprog || errflag)
>         return;
>
> +    dont_queue_signals();
> +
>      dotrapargs(sig, sigtrapped+sig, funcprog);
> +
> +    restore_queue_signals(q);
>  }
>

  reply	other threads:[~2015-09-02  6:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-01 23:07 Vincent Lefevre
2015-09-01 23:14 ` Vincent Lefevre
2015-09-02  0:13 ` Vincent Lefevre
2015-09-02  2:14   ` Bart Schaefer
2015-09-02  6:00     ` Mathias Fredriksson [this message]
2015-09-04 22:39     ` Mathias Fredriksson
2015-09-06 17:38       ` Peter Stephenson
2015-09-10 14:25         ` Bart Schaefer
2015-09-10 14:51           ` Infinite loop on exit Peter Stephenson
2015-09-10 15:43             ` Bart Schaefer
2015-09-10 15:55               ` Peter Stephenson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CA+=GgY4-V9-yn7-q0b3UaaS4q8ji-AR3tMFPPZ1Fs=fv94oVUQ@mail.gmail.com' \
    --to=mafredri@gmail.com \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).