Commit | Line | Data |
---|---|---|
bd2eadcc KA |
1 | # include <signal.h> |
2 | ||
3 | # ifdef SIGTSTP | |
4 | ||
5 | # include "curses.ext" | |
6 | ||
7 | /* | |
8 | * handle stop and start signals | |
9 | * | |
10 | * %G% (Berkeley) @(#)tstp.c 1.1 | |
11 | */ | |
12 | tstp() { | |
13 | ||
14 | SGTTY tty; | |
15 | # ifdef DEBUG | |
16 | if (outf) | |
17 | fflush(outf); | |
18 | # endif | |
19 | tty = _tty; | |
20 | mvcur(0, COLS - 1, LINES - 1, 0); | |
21 | endwin(); | |
22 | fflush(stdout); | |
23 | kill(0, SIGTSTP); | |
24 | signal(SIGTSTP, tstp); | |
25 | _tty = tty; | |
26 | stty(_tty_ch, &_tty); | |
27 | wrefresh(curscr); | |
28 | } | |
29 | # endif |