Fix condition to fork subshell

Resolves: #1462347
This commit is contained in:
Siteshwar Vashisht 2017-08-14 15:35:29 +02:00
parent 01b2471170
commit c4d3e851d9
2 changed files with 22 additions and 1 deletions

View File

@ -0,0 +1,14 @@
diff --git a/src/cmd/ksh93/sh/xec.c b/src/cmd/ksh93/sh/xec.c
--- a/src/cmd/ksh93/sh/xec.c
+++ b/src/cmd/ksh93/sh/xec.c
@@ -1647,8 +1647,9 @@ int sh_exec(register const Shnode_t *t, int flags)
{
if (!unpipe)
unpipe = iousepipe(shp);
- sh_subfork();
}
+
+ sh_subfork();
}
}
no_fork = !ntflag && !(type&(FAMP|FPOU)) && !shp->subshell &&

View File

@ -8,7 +8,7 @@ URL: http://www.kornshell.com/
#CPL everywhere else (for KSH itself)
License: CPL
Version: %{releasedate}
Release: 39%{?dist}
Release: 40%{?dist}
Source0: http://www.research.att.com/~gsf/download/tgz/ast-ksh.%{release_date}.tgz
Source1: http://www.research.att.com/~gsf/download/tgz/INIT.%{release_date}.tgz
Source2: kshcomp.conf
@ -193,6 +193,9 @@ Patch79: ksh-20120801-glibc-build-fix.patch
# rhbz#1459000
Patch80: ksh-20120801-jobwait-sigstop.patch
# rhbz#1462347
Patch81: ksh-20120801-subshell-jobwait.patch
Conflicts: pdksh
Requires: coreutils, diffutils, chkconfig
BuildRequires: bison
@ -316,6 +319,10 @@ fi
%config(noreplace) %{_sysconfdir}/binfmt.d/kshcomp.conf
%changelog
* Mon Aug 14 2017 Siteshwar Vashisht <svashisht@redhat.com> - 20120801-40
- Fix condition to fork subshell
Resolves: #1462347
* Mon Aug 14 2017 Siteshwar Vashisht <svashisht@redhat.com> - 20120801-39
- Set terminal foreground process group while resuming process
Resolves: #1459000