From 53cb4b0248bc988b60572ce499bf58b300fdaf6b Mon Sep 17 00:00:00 2001 From: Jfreegman Date: Sun, 15 Jun 2014 15:36:29 -0400 Subject: [PATCH] ignore ^C --- src/toxic.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/toxic.c b/src/toxic.c index d9e5bbf..924f031 100644 --- a/src/toxic.c +++ b/src/toxic.c @@ -439,6 +439,11 @@ void exit_toxic(Tox *m) exit(EXIT_SUCCESS); } +void ignore_SIGINT(int sig) +{ + return; +} + static void do_toxic(Tox *m, ToxWindow *prompt) { pthread_mutex_lock(&Winthread.lock); @@ -628,6 +633,7 @@ int main(int argc, char *argv[]) sort_friendlist_index(); prompt_init_statusbar(prompt, m); + signal(SIGINT, ignore_SIGINT); while (true) { update_unix_time();