Dr. Werner Fink 2014-05-27 12:12:43 +00:00 committed by Git OBS Bridge
parent 7dfd28d4c5
commit 054a9caf99
3 changed files with 19 additions and 0 deletions

View File

@ -0,0 +1,11 @@
--- startproc.c
+++ startproc.c 2014-05-27 12:08:10.498235871 +0000
@@ -624,7 +624,7 @@ static int do_start(const char *inname,
char * redirect;
if (!(redirect = getenv("REDIRECT")))
redirect = "/dev/tty";
- if ((tty = open(redirect,O_WRONLY|O_NONBLOCK,0)) < 0)
+ if ((tty = open(redirect,O_RDWR|O_NONBLOCK,0)) < 0)
error(LSB_PROOF," cannot open %s: %s\n", redirect, strerror(errno));
dup2(tty, fileno(stdin));
dup2(tty, fileno(stdout));

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed May 21 13:49:37 CEST 2014 - draht@suse.de
- open("/dev/tty", ...) should use O_RDWR, not O_WRONLY. Otherwise,
after dup2(fd, 0);, a process cannot read from stdin. [bnc#863518]
-------------------------------------------------------------------
Fri Feb 7 15:42:34 UTC 2014 - werner@suse.de

View File

@ -73,6 +73,7 @@ Patch12: %{name}-%{version}dsf-sulogin.diff
# PATCH-FIX-SUSE -- sulogin: find suitable console device even if first is not usable
Patch13: %{name}-%{version}dsf-xen.patch
Patch30: killproc-%{KPVER}.dif
Patch31: killproc-2.18-open_flags.dif
Patch40: showconsole-%{SCVER}.dif
Patch41: showconsole-1.16-deadlock.diff
Patch42: showconsole-1.16-glibc.dif
@ -143,6 +144,7 @@ pushd doc
popd
pushd ../killproc-%{KPVER}
%patch30
%patch31 -p0 -b .dialog
ln -t../%{name}-%{SIVER}dsf/doc/killproc README
popd
pushd ../showconsole-%{SCVER}