[PATCH 3 of 3] chg: forward job control signals to worker process (issue5051)
Yuya Nishihara
yuya at tcha.org
Thu Feb 11 22:26:20 EST 2016
On Thu, 11 Feb 2016 12:05:28 -0800, Sean Farley wrote:
> Yuya Nishihara <yuya at tcha.org> writes:
> > # HG changeset patch
> > # User Yuya Nishihara <yuya at tcha.org>
> > # Date 1453210319 -32400
> > # Tue Jan 19 22:31:59 2016 +0900
> > # Node ID 63251841f5f927f677b90957eec1230017f3a515
> > # Parent def82508e22c33bdfe042fd372bddf6dc3f93e2c
> > chg: forward job control signals to worker process (issue5051)
> >
> > This is necessary to suspend/resume long pulls, interactive curses session,
> > etc.
> >
> > The implementation is based on emacsclient, but our version doesn't test if
> > chg process is foreground or not before propagating SIGCONT. This is because
> > chg isn't always an interactive session. If we copy the SIGTTIN/SIGTTOU
> > emulation from emacsclient, non-interactive session can't be moved to a
> > background job.
> >
> > $ chg pull
> > ^Z
> > suspended
> > $ bg %1
> > [1] continued
> > [1] suspended (tty input) # wrong
> >
> > https://github.com/emacs-mirror/emacs/blob/0e96320/lib-src/emacsclient.c#L1094
>
> Took me a while but I was finally able to verify the before behavior and
> that these patches do indeed fix it. Great job, Yuya!
This problem was mostly investigated by Jun Wu. So kudos to him!
More information about the Mercurial-devel
mailing list