Mercurial > ~mikael > mcabber > hg
comparison mcabber/mcabber/main.c @ 2071:a5acc2a1af53
Adds SIGHUP to signal handling.
author | Dominik George <nik@naturalnet.de> |
---|---|
date | Sat, 14 Sep 2013 00:29:20 +0200 |
parents | 0cb8ea02e472 |
children | f56c214a19dc |
comparison
equal
deleted
inserted
replaced
2070:dd8ae0abfc68 | 2071:a5acc2a1af53 |
---|---|
116 signal(SIGCHLD, sig_handler); | 116 signal(SIGCHLD, sig_handler); |
117 } else if (signum == SIGTERM) { | 117 } else if (signum == SIGTERM) { |
118 mcabber_terminate("Killed by SIGTERM"); | 118 mcabber_terminate("Killed by SIGTERM"); |
119 } else if (signum == SIGINT) { | 119 } else if (signum == SIGINT) { |
120 mcabber_terminate("Killed by SIGINT"); | 120 mcabber_terminate("Killed by SIGINT"); |
121 } else if (signum == SIGHUP) { | |
122 mcabber_terminate("Killed by SIGHUP"); | |
121 #ifdef USE_SIGWINCH | 123 #ifdef USE_SIGWINCH |
122 } else if (signum == SIGWINCH) { | 124 } else if (signum == SIGWINCH) { |
123 if (scr_curses_status()) | 125 if (scr_curses_status()) |
124 ungetch(KEY_RESIZE); | 126 ungetch(KEY_RESIZE); |
125 #endif | 127 #endif |
330 | 332 |
331 credits(); | 333 credits(); |
332 | 334 |
333 signal(SIGTERM, sig_handler); | 335 signal(SIGTERM, sig_handler); |
334 signal(SIGINT, sig_handler); | 336 signal(SIGINT, sig_handler); |
337 signal(SIGHUP, sig_handler); | |
335 signal(SIGCHLD, sig_handler); | 338 signal(SIGCHLD, sig_handler); |
336 #ifdef USE_SIGWINCH | 339 #ifdef USE_SIGWINCH |
337 signal(SIGWINCH, sig_handler); | 340 signal(SIGWINCH, sig_handler); |
338 #endif | 341 #endif |
339 signal(SIGPIPE, SIG_IGN); | 342 signal(SIGPIPE, SIG_IGN); |