]> git.ipfire.org Git - thirdparty/qemu.git/commit
ui: return NULL when getting cursor without a console
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Sun, 19 Mar 2023 11:10:17 +0000 (15:10 +0400)
committerMichael Tokarev <mjt@tls.msk.ru>
Wed, 28 Jun 2023 15:50:48 +0000 (18:50 +0300)
commitdc4c852d4d4bf5412c740b4c67fa20d7beb8f2e3
treeb21dc9ab0d8ae12bd9597fdc3f3cb0d25aa4c85f
parentaab37b2002811f112d5c26337473486d7d585881
ui: return NULL when getting cursor without a console

VNC may try to get the current cursor even when there are no consoles
and crashes. Simple reproducer is qemu with -nodefaults.

Fixes: (again)
https://gitlab.com/qemu-project/qemu/-/issues/1548

Fixes: commit 385ac97f8 ("ui: keep current cursor with QemuConsole")
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230428154807.2143652-1-marcandre.lureau@redhat.com>
(cherry picked from commit 333e7599a0d723801235f675719008ce43db93e3)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
ui/console.c