rpms/dash/F-10 dash-do-not-close-stderr.patch,NONE,1.1
Andreas Thienemann
ixs at fedoraproject.org
Tue May 26 20:30:58 UTC 2009
Author: ixs
Update of /cvs/pkgs/rpms/dash/F-10
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv30078
Added Files:
dash-do-not-close-stderr.patch
Log Message:
* Tue May 26 2009 Andreas Thienemann <andreas at bawue.net> 0.5.4-4
- Added patch from upstream git to not close stdout on err. This improves
initramfs use of dash.
dash-do-not-close-stderr.patch:
--- NEW FILE dash-do-not-close-stderr.patch ---
commit fcc4134a7b76d82d39dea635c41ec593a41d6d19
Author: Herbert Xu <herbert at gondor.apana.org.au>
Date: Sun Feb 22 19:29:48 2009 +0800
[JOBS] Do not close stderr when /dev/tty fails to open
As it stands if we fail to open /dev/tty we end up closing stderr
after saving it at a higher fd.
Thanks to David van Gorkom for reporting this.
Signed-off-by: Herbert Xu <herbert at gondor.apana.org.au>
diff --git a/src/jobs.c b/src/jobs.c
index 69a84f7..b1ab7ab 100644
--- a/src/jobs.c
+++ b/src/jobs.c
@@ -195,6 +195,9 @@ setjobctl(int on)
while (!isatty(fd))
if (--fd < 0)
goto out;
+ fd = dup(fd);
+ if (fd < 0)
+ goto out;
}
fd = savefd(fd);
do { /* while we are in the background */
More information about the scm-commits
mailing list