|
From: | Marc-André Lureau |
Subject: | Re: [PATCH] qxl: fix segfault |
Date: | Tue, 24 Nov 2020 16:44:33 +0400 |
Add missing sanity check.
Reproducer: run qemu with "-device qxl" but without "-spice ..."
Fixes: 0d9b90ce5c73 ("console: make QMP/HMP screendump run in coroutine")
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
ui/console.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/ui/console.c b/ui/console.c
index e07d2c380df7..53dee8e26b17 100644
--- a/ui/console.c
+++ b/ui/console.c
@@ -264,7 +264,9 @@ static void gui_setup_refresh(DisplayState *ds)
void graphic_hw_update_done(QemuConsole *con)
{
- qemu_co_queue_restart_all(&con->dump_queue);
+ if (con) {
+ qemu_co_queue_restart_all(&con->dump_queue);
+ }
}
void graphic_hw_update(QemuConsole *con)
--
2.27.0
[Prev in Thread] | Current Thread | [Next in Thread] |