* src/su.c: Do not set terminal in RAW mode in case of earlier
failure.
* src/su.c: Fail if the process group leader or the controlling
terminal cannot be set.
+ * src/su.c: Do not set terminal in RAW mode in case of earlier
+ failure.
2013-08-19 Nicolas François <nicolas.francois@centraliens.net>
}
}
- if (have_tty == true) {
+ if ((0 == caught) && (have_tty == true)) {
/* Set RAW mode */
termset_new = termset_save;
cfmakeraw (&termset_new);
}
}
} while (!stop);
- }
-
if (have_tty == true) {
close (fd_pts);
if (tcsetattr (STDIN_FILENO, TCSANOW, &termset_save) == -1)
fprintf (stderr, _("%s: Cannot reset termios attributes\n"), Prog);
}
+ }
if (0 != caught) {
(void) fputs ("\n", stderr);