mirror of
git://git.code.sf.net/p/cdesktopenv/code
synced 2025-03-09 15:50:02 +00:00
Fix SIGHUP on termination (Solaris patch 260-22964338)
This fixes the following bug filed with Solaris: "22964338 ksh93 appears to send SIGHUP to unrelated processes on occasion". It is fixed by applying this patch by Lijo George from the Solaris repo: https://github.com/oracle/solaris-userland/blob/master/components/ksh93/patches/260-22964338.patch The ksh2020 upstream rejected this, but if it's in production use in Solaris, Solaris, it's probably good enough for 93u+m. If any breakage is left, it can be fixed later. https://github.com/att/ast/pull/1 src/cmd/ksh93/include/jobs.h, src/cmd/ksh93/sh/fault.c, src/cmd/ksh93/sh/jobs.c: - Use a new job_hup() function instead of job_kill() to send SIGHUP to job processes on termination. The new function checks if a job is in fact still live before issuing SIGHUP to it.
This commit is contained in:
parent
ab98ec65e4
commit
62cf88d0df
3 changed files with 50 additions and 1 deletions
|
@ -634,7 +634,7 @@ void sh_done(void *ptr, register int sig)
|
|||
#endif
|
||||
#ifdef JOBS
|
||||
if((sh_isoption(SH_INTERACTIVE) && shp->login_sh) || (!sh_isoption(SH_INTERACTIVE) && (sig==SIGHUP)))
|
||||
job_walk(sfstderr,job_terminate,SIGHUP,NIL(char**));
|
||||
job_walk(sfstderr, job_hup, SIGHUP, NIL(char**));
|
||||
#endif /* JOBS */
|
||||
job_close(shp);
|
||||
if(nv_search("VMTRACE", shp->var_tree,0))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue