summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2015-10-08 20:19:14 +0100
committerMaxime Coste <frrrwww@gmail.com>2015-10-08 20:23:32 +0100
commit0d8b9c6677f67cf9624cb5a498a3aa7969a449b6 (patch)
treeb1b109296ea7748ef877a80fb37ac54d9f891eb4 /src
parent473196e18d910f9544333642d7f66c02c8c59113 (diff)
Tweak handling of SIGINT
Diffstat (limited to 'src')
-rw-r--r--src/main.cc1
-rw-r--r--src/ncurses_ui.cc2
2 files changed, 1 insertions, 2 deletions
diff --git a/src/main.cc b/src/main.cc
index 9da4ddb3..fe045b76 100644
--- a/src/main.cc
+++ b/src/main.cc
@@ -648,6 +648,7 @@ int main(int argc, char* argv[])
signal(SIGQUIT, signal_handler);
signal(SIGTERM, signal_handler);
signal(SIGPIPE, SIG_IGN);
+ signal(SIGINT, [](int){});
signal(SIGCHLD, [](int){});
Vector<String> params;
diff --git a/src/ncurses_ui.cc b/src/ncurses_ui.cc
index 259af46d..4fd6cfbc 100644
--- a/src/ncurses_ui.cc
+++ b/src/ncurses_ui.cc
@@ -260,7 +260,6 @@ NCursesUI::NCursesUI()
signal(SIGWINCH, on_term_resize);
signal(SIGCONT, on_term_resize);
- signal(SIGINT, [](int){});
check_resize(true);
@@ -276,7 +275,6 @@ NCursesUI::~NCursesUI()
restore_colors();
signal(SIGWINCH, SIG_DFL);
signal(SIGCONT, SIG_DFL);
- signal(SIGINT, SIG_DFL);
}
void NCursesUI::Window::create(const CharCoord& p, const CharCoord& s)