]> git.proxmox.com Git - qemu.git/commitdiff
block/raw_bsd: Employ error parameter
authorMax Reitz <mreitz@redhat.com>
Thu, 10 Oct 2013 13:44:00 +0000 (15:44 +0200)
committerKevin Wolf <kwolf@redhat.com>
Fri, 11 Oct 2013 14:50:00 +0000 (16:50 +0200)
Propagate errors in raw_create rather than directly reporting and
afterwards discarding them.

Signed-off-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block/raw_bsd.c

index d61906bcc2786a945fb4d62aac03653e2e96172c..0078c1baebf2f17ad804b20fabfbb7d177fb17f2 100644 (file)
@@ -140,8 +140,7 @@ static int raw_create(const char *filename, QEMUOptionParameter *options,
 
     ret = bdrv_create_file(filename, options, &local_err);
     if (error_is_set(&local_err)) {
-        qerror_report_err(local_err);
-        error_free(local_err);
+        error_propagate(errp, local_err);
     }
     return ret;
 }