Loading blockdev.c +9 −2 Original line number Diff line number Diff line Loading @@ -526,7 +526,7 @@ DriveInfo *drive_init(QemuOpts *opts, int default_to_scsi) } else if (ro == 1) { if (type != IF_SCSI && type != IF_VIRTIO && type != IF_FLOPPY && type != IF_NONE) { error_report("readonly not supported by this bus type"); return NULL; goto err; } } Loading @@ -536,12 +536,19 @@ DriveInfo *drive_init(QemuOpts *opts, int default_to_scsi) if (ret < 0) { error_report("could not open disk image %s: %s", file, strerror(-ret)); return NULL; goto err; } if (bdrv_key_required(dinfo->bdrv)) autostart = 0; return dinfo; err: bdrv_delete(dinfo->bdrv); qemu_free(dinfo->id); QTAILQ_REMOVE(&drives, dinfo, next); qemu_free(dinfo); return NULL; } void do_commit(Monitor *mon, const QDict *qdict) Loading Loading
blockdev.c +9 −2 Original line number Diff line number Diff line Loading @@ -526,7 +526,7 @@ DriveInfo *drive_init(QemuOpts *opts, int default_to_scsi) } else if (ro == 1) { if (type != IF_SCSI && type != IF_VIRTIO && type != IF_FLOPPY && type != IF_NONE) { error_report("readonly not supported by this bus type"); return NULL; goto err; } } Loading @@ -536,12 +536,19 @@ DriveInfo *drive_init(QemuOpts *opts, int default_to_scsi) if (ret < 0) { error_report("could not open disk image %s: %s", file, strerror(-ret)); return NULL; goto err; } if (bdrv_key_required(dinfo->bdrv)) autostart = 0; return dinfo; err: bdrv_delete(dinfo->bdrv); qemu_free(dinfo->id); QTAILQ_REMOVE(&drives, dinfo, next); qemu_free(dinfo); return NULL; } void do_commit(Monitor *mon, const QDict *qdict) Loading