summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr.bin/systat/keyboard.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/usr.bin/systat/keyboard.c b/usr.bin/systat/keyboard.c
index e467eed0907..5aadd2dcb0a 100644
--- a/usr.bin/systat/keyboard.c
+++ b/usr.bin/systat/keyboard.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: keyboard.c,v 1.16 2004/07/11 05:24:56 pvalchev Exp $ */
+/* $OpenBSD: keyboard.c,v 1.17 2005/08/01 22:51:50 millert Exp $ */
/* $NetBSD: keyboard.c,v 1.2 1995/01/20 08:51:59 jtc Exp $ */
/*-
@@ -34,7 +34,7 @@
#if 0
static char sccsid[] = "@(#)keyboard.c 8.1 (Berkeley) 6/6/93";
#endif
-static char rcsid[] = "$OpenBSD: keyboard.c,v 1.16 2004/07/11 05:24:56 pvalchev Exp $";
+static char rcsid[] = "$OpenBSD: keyboard.c,v 1.17 2005/08/01 22:51:50 millert Exp $";
#endif /* not lint */
#include <sys/types.h>
@@ -61,7 +61,10 @@ keyboard(void)
do {
if (gottstp) {
endwin();
- kill(getpid(), SIGSTOP);
+ signal(SIGTSTP, SIG_DFL);
+ kill(getpid(), SIGTSTP);
+ signal(SIGTSTP, sigtstp);
+ siginterrupt(SIGTSTP, 1);
gotwinch = 1;
gottstp = 0;
}