summaryrefslogtreecommitdiff
path: root/procps/top.c
diff options
context:
space:
mode:
Diffstat (limited to 'procps/top.c')
-rw-r--r--procps/top.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/procps/top.c b/procps/top.c
index a47150e..f4bb509 100644
--- a/procps/top.c
+++ b/procps/top.c
@@ -772,8 +772,10 @@ int top_main(int argc, char **argv)
/* unbuffered input, turn off echo */
new_settings.c_lflag &= ~(ISIG | ICANON | ECHO | ECHONL);
- signal(SIGTERM, sig_catcher);
- signal(SIGINT, sig_catcher);
+ bb_signals(0
+ + (1 << SIGTERM)
+ + (1 << SIGINT)
+ , sig_catcher);
tcsetattr(0, TCSANOW, (void *) &new_settings);
atexit(reset_term);
#endif /* FEATURE_USE_TERMIOS */