[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-block] [PULL 05/17] qemu-img: Avoid qerror_report_err() outside QM
From: |
Kevin Wolf |
Subject: |
[Qemu-block] [PULL 05/17] qemu-img: Avoid qerror_report_err() outside QMP handlers, again |
Date: |
Mon, 16 Mar 2015 17:57:09 +0100 |
From: Markus Armbruster <address@hidden>
qerror_report_err() is a transitional interface to help with
converting existing monitor commands to QMP. It should not be used
elsewhere. Replace by error_report_err().
Commit 6936f29 cleaned that up in qemu-img.c, but two calls have crept
in since. Take care of them the same way.
Signed-off-by: Markus Armbruster <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>
---
qemu-img.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/qemu-img.c b/qemu-img.c
index 82d9078..9dddfbe 100644
--- a/qemu-img.c
+++ b/qemu-img.c
@@ -274,8 +274,7 @@ static int print_block_option_help(const char *filename,
const char *fmt)
if (filename) {
proto_drv = bdrv_find_protocol(filename, true, &local_err);
if (!proto_drv) {
- qerror_report_err(local_err);
- error_free(local_err);
+ error_report_err(local_err);
qemu_opts_free(create_opts);
return 1;
}
@@ -1526,8 +1525,7 @@ static int img_convert(int argc, char **argv)
proto_drv = bdrv_find_protocol(out_filename, true, &local_err);
if (!proto_drv) {
- qerror_report_err(local_err);
- error_free(local_err);
+ error_report_err(local_err);
ret = -1;
goto out;
}
--
1.8.3.1
- [Qemu-block] [PULL 00/17] Block patches for 2.3.0-rc0, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 02/17] qemu-img: Fix convert, amend error messages for unknown options, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 03/17] block: Deprecate QCOW/QCOW2 encryption, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 01/17] iotests: Update 051's reference output, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 04/17] block: Fix block-set-write-threshold not to use funky error class, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 06/17] qcow2: Respect new_block in alloc_refcount_block(), Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 05/17] qemu-img: Avoid qerror_report_err() outside QMP handlers, again,
Kevin Wolf <=
- [Qemu-block] [PULL 09/17] monitor: Convert bdrv_find to blk_by_name, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 10/17] migration: Convert bdrv_find to blk_by_name, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 07/17] iotests: Add tests for refcount table growth, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 08/17] iotests: Test non-self-referential qcow2 refblocks, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 11/17] blockdev: Convert bdrv_find to blk_by_name, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 13/17] block/vpc: optimize vpc_co_get_block_status, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 16/17] block/vpc: rename footer->size -> footer->current_size, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 12/17] block: Drop bdrv_find, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 14/17] vpc: Ignore geometry for large images, Kevin Wolf, 2015/03/16
- [Qemu-block] [PULL 17/17] block/vpc: remove disabled code from get_sector_offset, Kevin Wolf, 2015/03/16