block/raw_bsd: Employ error parameter

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>
This commit is contained in:
Max Reitz 2013-10-10 15:44:00 +02:00 committed by Kevin Wolf
parent 1fa5cc839a
commit 92f1deec31
1 changed files with 1 additions and 2 deletions

View 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;
}