]> Git Repo - qemu.git/commitdiff
Revert "main-loop.c: Handle SIGINT, SIGHUP and SIGTERM synchronously"
authorJan Kiszka <[email protected]>
Mon, 27 Oct 2014 14:13:02 +0000 (14:13 +0000)
committerPeter Maydell <[email protected]>
Mon, 27 Oct 2014 15:05:09 +0000 (15:05 +0000)
This reverts commit 15124e142034d21341ec9f1a304a1dc5a6c25681. It breaks
debuggability of qemu and is no longer needed as the problem has
now been addressed in a different way.

Instead we provide a comment about why these signals must be
handled asynchronously.

Signed-off-by: Jan Kiszka <[email protected]>
Reviewed-by: Gonglei <[email protected]>
[PMM: added comment]
Signed-off-by: Peter Maydell <[email protected]>
main-loop.c

index d2e64f1fa49f6e0573bad4f017e96f506eebee9c..981bcb5f8e2ea9ff898aa2ccd74e3c5ef87bdf9e 100644 (file)
@@ -84,9 +84,11 @@ static int qemu_signal_init(void)
     sigaddset(&set, SIGIO);
     sigaddset(&set, SIGALRM);
     sigaddset(&set, SIGBUS);
-    sigaddset(&set, SIGINT);
-    sigaddset(&set, SIGHUP);
-    sigaddset(&set, SIGTERM);
+    /* SIGINT cannot be handled via signalfd, so that ^C can be used
+     * to interrupt QEMU when it is being run under gdb.  SIGHUP and
+     * SIGTERM are also handled asynchronously, even though it is not
+     * strictly necessary, because they use the same handler as SIGINT.
+     */
     pthread_sigmask(SIG_BLOCK, &set, NULL);
 
     sigdelset(&set, SIG_IPI);
This page took 0.026481 seconds and 4 git commands to generate.