register signal handler after initializing SDL.
SDL library initialization mangles signal handlers, so QEMU should
register them after initializing SDL. This was the case before and code
even have a comment about that. Fix it to be so again.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
diff --git a/vl.c b/vl.c
index 5c80600..4d9e503 100644
--- a/vl.c
+++ b/vl.c
@@ -3059,9 +3059,6 @@
cpu_synchronize_all_post_init();
- /* must be after terminal init, SDL library changes signal handlers */
- os_setup_signal_handling();
-
set_numa_modes();
current_machine = machine;
@@ -3117,6 +3114,9 @@
break;
}
+ /* must be after terminal init, SDL library changes signal handlers */
+ os_setup_signal_handling();
+
#ifdef CONFIG_VNC
/* init remote displays */
if (vnc_display) {