ui/gtk: fix crash at startup when no console is available
This patch fixes a segfault at QEMU startup, introduced in a0815632. gd_vc_find_current() return NULL, which is dereferenced without checking it. While at it, disable the whole 'View' menu if no console exists. Reproducer: qemu-system-i386 -M none -nodefaults Signed-off-by: NHervé Poussineau <hpoussin@reactos.org> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1483263585-8101-1-git-send-email-hpoussin@reactos.org Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
Showing