From: Christophe de Dinechin <dinec...@redhat.com>

Signed-off-by: Christophe de Dinechin <dinec...@redhat.com>
---
 src/spice-streaming-agent.cpp | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/src/spice-streaming-agent.cpp b/src/spice-streaming-agent.cpp
index e9ef310..9a5c4fa 100644
--- a/src/spice-streaming-agent.cpp
+++ b/src/spice-streaming-agent.cpp
@@ -280,10 +280,7 @@ static void handle_interrupt(int intr)
 
 static void register_interrupts(void)
 {
-    struct sigaction sa;
-
-    memset(&sa, 0, sizeof(sa));
-    sa.sa_handler = handle_interrupt;
+    struct sigaction sa = { .sa_handler = handle_interrupt };
     if ((sigaction(SIGINT, &sa, NULL) != 0) &&
         (sigaction(SIGTERM, &sa, NULL) != 0)) {
         syslog(LOG_WARNING, "failed to register signal handler %m");
-- 
2.13.5 (Apple Git-94)

_______________________________________________
Spice-devel mailing list
Spice-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/spice-devel

Reply via email to