Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: [PATCH] Do not send duplicate signals when MONITOR is set



On Mon, 2021-07-19 at 11:00 +0100, Peter Stephenson wrote:
> > On 18 July 2021 at 23:55 Lawrence Velázquez <larryv@xxxxxxx> wrote:
> > On Mon, Jun 14, 2021, at 3:19 PM, Peter Stephenson wrote:
> > > On Mon, 2021-06-07 at 11:45 -0700, Bart Schaefer wrote:
> > > > On Mon, Jun 7, 2021 at 10:28 AM Erik Paulson <epaulson10@xxxxxxxxx> wrote:
> > > > > 
> > > > > I run emacs as a daemon and use the emacsclient program to connect to
> > > > > it. I noticed that when I suspended the emacsclient program and
> > > > > resumed it in zsh, the program would sporadically crash. After digging
> > > > > into the code, I realized that emacsclient was receiving two SIGCONTs,
> > > > > which caused it to send a malformed command to the daemon.
> > > > > 
> > > > > I found that this return used to be present, but was removed in
> > > > > https://www.zsh.org/mla/workers/2018/msg01338.html while addressing
> > > > > another emacs issue.
> > 
> > ...
> > > I would hazard that as SIGCONT is probably the most difficult case ---
> > > the only one where you specifically want the process to be running
> > > afterwards --- if this patch improves things there, it's prohably not
> > > doing a lot of harm in most cases.
> > 
> > ...
> > Anything else on this?
> 
> Unless anyone can point to a fundamental error in my summary above, I
> suggest we apply this and and see what happens.  At the absolute least,
> I'm pretty sure we're not going to get any further without trying it
> out in earnest, and looking for remaining oddities.

I've committed this, so we should keep a look out for missing signals,
though they're going to be in very obscure contexts even if there are
any.

pws





Messages sorted by: Reverse Date, Date, Thread, Author