diff --git a/devicemodel/hw/pci/virtio/virtio_console.c b/devicemodel/hw/pci/virtio/virtio_console.c index e7de20b7c..209cf27a4 100644 --- a/devicemodel/hw/pci/virtio/virtio_console.c +++ b/devicemodel/hw/pci/virtio/virtio_console.c @@ -890,7 +890,8 @@ virtio_console_init(struct vmctx *ctx, struct pci_vdev *dev, char *opts) if (backend[0] == '@') { is_console = true; backend++; - } + } else + is_console = false; be_type = virtio_console_get_be_type(backend); if (be_type == VIRTIO_CONSOLE_BE_INVALID) {