git://git.jankratochvil.net
/
nethome.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f4cf340
)
Fixed a bug of uninitialized TERMIOS.
author
lace
<>
Tue, 10 Jul 2007 21:50:51 +0000
(21:50 +0000)
committer
lace
<>
Tue, 10 Jul 2007 21:50:51 +0000
(21:50 +0000)
src/orphanripper.c
patch
|
blob
|
history
diff --git
a/src/orphanripper.c
b/src/orphanripper.c
index
cf3039f
..
7bea08d
100644
(file)
--- a/
src/orphanripper.c
+++ b/
src/orphanripper.c
@@
-86,6
+86,13
@@
static int spawn (char **argv)
assert (i == 0);
/* With TERMP passed as NULL we get "\n" -> "\r\n". */
assert (i == 0);
/* With TERMP passed as NULL we get "\n" -> "\r\n". */
+ termios.c_iflag = IGNBRK | IGNPAR;
+ termios.c_oflag = 0;
+ termios.c_cflag = CS8 | CREAD | CLOCAL | HUPCL | B9600;
+ termios.c_lflag = IEXTEN | NOFLSH;
+ memset (termios.c_cc, _POSIX_VDISABLE, sizeof (termios.c_cc));
+ termios.c_cc[VTIME] = 0;
+ termios.c_cc[VMIN ] = 1;
cfmakeraw (&termios);
#ifdef FLUSHO
/* Workaround a readline deadlock bug in _get_tty_settings(). */
cfmakeraw (&termios);
#ifdef FLUSHO
/* Workaround a readline deadlock bug in _get_tty_settings(). */