diff options
author | Benny Baumann <BenBE@geshi.org> | 2021-07-13 20:38:08 +0200 |
---|---|---|
committer | BenBE <BenBE@geshi.org> | 2021-07-13 20:42:30 +0200 |
commit | bf22a8fb13c9495466051caa5a0c0e9c1f9de0df (patch) | |
tree | d7f87fdcad26949c3097d7fe772141706532f332 /CRT.c | |
parent | 09c7e3e136d30e00759dc28b4614df61b869cb71 (diff) |
Add SIGINT handler
This SIGINT handler is installed on top of an optional
handler that some curses/ncurses implementations provide.
This ensures the curser is properly reset when hitting Ctrl+C.
Diffstat (limited to 'CRT.c')
-rw-r--r-- | CRT.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -885,6 +885,7 @@ void CRT_init(const Settings* settings, bool allowUnicode) { sigaction (SIGSYS, &act, &old_sig_handler[SIGSYS]); sigaction (SIGABRT, &act, &old_sig_handler[SIGABRT]); + signal(SIGINT, CRT_handleSIGTERM); signal(SIGTERM, CRT_handleSIGTERM); signal(SIGQUIT, CRT_handleSIGTERM); |