Re: non-interactive sh and SIGTERM

2018-11-26 Thread Olivier Taïbi
Thanks for the explanation, it makes sense to use pgids for that purpose. In the case in which I am interested (vimtex plugin failing to kill latexmk, which works on another machine running debian linux) I guessed that the plugin sent a SIGTERM signal only to the 'sh -c' process, which would work

Re: non-interactive sh and SIGTERM

2018-11-25 Thread Philip Guenther
On Fri, Nov 23, 2018 at 1:51 PM Olivier Taïbi wrote: > Sorry about the wrong report, I just tested again and I can see the same > behaviour with OpenBSD 6.4: sending SIGTERM to the sh process after > launching sh -c 'sleep 1000' does not result in sh sending a SIGTERM to > the sleep process. >

Re: non-interactive sh and SIGTERM

2018-11-23 Thread Olivier Taïbi
Sorry about the wrong report, I just tested again and I can see the same behaviour with OpenBSD 6.4: sending SIGTERM to the sh process after launching sh -c 'sleep 1000' does not result in sh sending a SIGTERM to the sleep process. Philip, what was your test? Thanks On Fri, Nov 23, 2018 at

Re: non-interactive sh and SIGTERM

2018-11-23 Thread Olivier Taïbi
After some testing, this issue does not seem to be directly caused by ksh. Compiling ksh from a year ago, I get the same behaviour: SIGTERM is not passed on to child. I'm not sure what to try next. Bisecting /usr/src? On Fri, Nov 23, 2018 at 08:55:16AM +0100, Olivier Taïbi wrote: > On Thu, Nov

Re: non-interactive sh and SIGTERM

2018-11-22 Thread Olivier Taïbi
On Thu, Nov 22, 2018 at 05:14:38PM -0800, Philip Guenther wrote: > On Thu, Nov 22, 2018 at 3:08 PM Olivier Taïbi wrote: > > > It seems that non-interactive sh(1) (i.e. sh -c command or sh file) > > ignores the TERM signal. I'm surprised, is this the intended behaviour? > > The man page says that

Re: non-interactive sh and SIGTERM

2018-11-22 Thread Philip Guenther
On Thu, Nov 22, 2018 at 3:08 PM Olivier Taïbi wrote: > It seems that non-interactive sh(1) (i.e. sh -c command or sh file) > ignores the TERM signal. I'm surprised, is this the intended behaviour? > The man page says that interactive shells will ignore SIGTERM, but does > not mention the

non-interactive sh and SIGTERM

2018-11-22 Thread Olivier Taïbi
It seems that non-interactive sh(1) (i.e. sh -c command or sh file) ignores the TERM signal. I'm surprised, is this the intended behaviour? The man page says that interactive shells will ignore SIGTERM, but does not mention the non-interactive case.