From 7b542d0a45d035e9b415d3e6308f74c066ad2382 Mon Sep 17 00:00:00 2001 From: Arun Prakash Jana Date: Sat, 9 Feb 2019 06:03:24 +0530 Subject: [PATCH] initialize on declaration --- src/nnn.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/nnn.c b/src/nnn.c index f69216ff..02c53fa0 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -4222,8 +4222,7 @@ int main(int argc, char *argv[]) cfg.restrict0b = 1; /* Ignore/handle certain signals */ - struct sigaction act; - memset(&act, 0, sizeof(act)); + struct sigaction act = {}; act.sa_sigaction = &sigint_handler; act.sa_flags = SA_SIGINFO; if (sigaction(SIGINT, &act, NULL) < 0) {