2013-10-30 12:41:35 +00:00
|
|
|
diff -up ksh-20120801/src/cmd/ksh93/sh/xec.c.mtty ksh-20120801/src/cmd/ksh93/sh/xec.c
|
2014-07-24 11:13:05 +00:00
|
|
|
--- ksh-20120801/src/cmd/ksh93/sh/xec.c.mtty 2014-01-22 16:52:06.441608750 +0100
|
|
|
|
+++ ksh-20120801/src/cmd/ksh93/sh/xec.c 2014-01-22 16:52:06.485608361 +0100
|
|
|
|
@@ -3163,7 +3169,7 @@ pid_t _sh_fork(Shell_t *shp,register pid
|
2013-10-30 12:41:35 +00:00
|
|
|
* completed. Make parent the job group id.
|
|
|
|
*/
|
|
|
|
if(postid==0)
|
|
|
|
- job.curpgid = parent;
|
2014-07-24 11:13:05 +00:00
|
|
|
+ job.curpgid = job.jobcontrol?parent:getpid();
|
2013-10-30 12:41:35 +00:00
|
|
|
if(job.jobcontrol || (flags&FAMP))
|
|
|
|
{
|
|
|
|
if(setpgid(parent,job.curpgid)<0 && errno==EPERM)
|