]> git.proxmox.com Git - mirror_qemu.git/blobdiff - blockdev.c
error: Eliminate error_propagate() with Coccinelle, part 1
[mirror_qemu.git] / blockdev.c
index 625c8ff3f205b2f09e377478ac7b2f64fb7a72bc..705869d849aaec53e9d15c24122c8512c9037099 100644 (file)
@@ -509,8 +509,7 @@ static BlockBackend *blockdev_init(const char *file, QDict *bs_opts,
         goto err_no_opts;
     }
 
-    if (!qemu_opts_absorb_qdict(opts, bs_opts, &error)) {
-        error_propagate(errp, error);
+    if (!qemu_opts_absorb_qdict(opts, bs_opts, errp)) {
         goto early_err;
     }
 
@@ -827,8 +826,7 @@ DriveInfo *drive_new(QemuOpts *all_opts, BlockInterfaceType block_default_type,
 
     for (i = 0; i < ARRAY_SIZE(opt_renames); i++) {
         if (!qemu_opt_rename(all_opts, opt_renames[i].from,
-                             opt_renames[i].to, &local_err)) {
-            error_propagate(errp, local_err);
+                             opt_renames[i].to, errp)) {
             return NULL;
         }
     }