]> granicus.if.org Git - procps-ng/commitdiff
0107-top: Initialize struct sigaction in before().
authorQualys Security Advisory <qsa@qualys.com>
Thu, 1 Jan 1970 00:00:00 +0000 (00:00 +0000)
committerCraig Small <csmall@enc.com.au>
Sat, 9 Jun 2018 11:35:20 +0000 (21:35 +1000)
top/top.c

index 60613ca9068b56baebc9db44819a51b8b7f92c76..eefa6358cf4653af320e6e9b3aaa61ba56122785 100644 (file)
--- a/top/top.c
+++ b/top/top.c
@@ -3112,6 +3112,7 @@ static void before (char *me) {
 #define SIGRTMAX 32
 #endif
    // lastly, establish a robust signals environment
+   memset(&sa, 0, sizeof(sa));
    sigemptyset(&sa.sa_mask);
    // with user position preserved through SIGWINCH, we must avoid SA_RESTART
    sa.sa_flags = 0;