diff options
Diffstat (limited to 'blockdev.c')
-rw-r--r-- | blockdev.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/blockdev.c b/blockdev.c index 31d5eaf6bf..b52ed9de86 100644 --- a/blockdev.c +++ b/blockdev.c @@ -504,9 +504,8 @@ static BlockBackend *blockdev_init(const char *file, QDict *bs_opts, /* Check common options by copying from bs_opts to opts, all other options * stay in bs_opts for processing by bdrv_open(). */ id = qdict_get_try_str(bs_opts, "id"); - opts = qemu_opts_create(&qemu_common_drive_opts, id, 1, &error); - if (error) { - error_propagate(errp, error); + opts = qemu_opts_create(&qemu_common_drive_opts, id, 1, errp); + if (!opts) { goto err_no_opts; } |