]> xenbits.xensource.com Git - qemu-upstream-4.5-testing.git/commitdiff
linux-user/signal.c: Don't pass sigaction uninitialised sa_flags
authorPeter Maydell <peter.maydell@linaro.org>
Mon, 17 Feb 2014 18:55:32 +0000 (18:55 +0000)
committerRiku Voipio <riku.voipio@linaro.org>
Tue, 18 Feb 2014 14:54:06 +0000 (16:54 +0200)
When forcing a fatal signal, we weren't initialising the sa_flags
field in the struct sigaction we used to reset the signal handler
to SIG_DFL.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
linux-user/signal.c

index 82e8592546f633c637dae31bdfc3f469b3a4fee6..04638e2ead79722b9f5030effdf20ba26e64a1d1 100644 (file)
@@ -420,6 +420,7 @@ static void QEMU_NORETURN force_sig(int target_sig)
      * it to arrive. */
     sigfillset(&act.sa_mask);
     act.sa_handler = SIG_DFL;
+    act.sa_flags = 0;
     sigaction(host_sig, &act, NULL);
 
     /* For some reason raise(host_sig) doesn't send the signal when