mirror of
https://github.com/qemu/qemu.git
synced 2024-12-18 09:43:38 +08:00
check for active_console before using it
Other vga_hw_* functions do the same. Fixes a segmentation fault. Trigger: boot with -nodefaults, then connect via vnc. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
4091da4b7c
commit
26572b8a0e
@ -167,7 +167,7 @@ void vga_hw_update(void)
|
|||||||
|
|
||||||
void vga_hw_invalidate(void)
|
void vga_hw_invalidate(void)
|
||||||
{
|
{
|
||||||
if (active_console->hw_invalidate)
|
if (active_console && active_console->hw_invalidate)
|
||||||
active_console->hw_invalidate(active_console->hw);
|
active_console->hw_invalidate(active_console->hw);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user