[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v20 11/26] qcow2.c: replace QEMUOptionParameter
From: |
Eric Blake |
Subject: |
Re: [Qemu-devel] [PATCH v20 11/26] qcow2.c: replace QEMUOptionParameter with QemuOpts in create |
Date: |
Wed, 12 Feb 2014 17:30:11 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.3.0 |
On 02/11/2014 11:33 PM, Chunyan Liu wrote:
> qcow2.c: replace QEMUOptionParameter with QemuOpts in 'qemu-img create'.
>
> Signed-off-by: Dong Xu Wang <address@hidden>
> Signed-off-by: Chunyan Liu <address@hidden>
> ---
> block/qcow2.c | 176 ++++++++++++++++++++++++++++----------------------------
> 1 files changed, 88 insertions(+), 88 deletions(-)
>
> + buf = NULL;
> + buf = qemu_opt_get_del(opts, BLOCK_OPT_COMPAT_LEVEL);
Dead assignment to NULL.
> + if (!buf || !strcmp(buf, "0.10")) {
> + version = 2;
> + } else if (!strcmp(buf, "1.1")) {
> + version = 3;
> + } else {
> + fprintf(stderr, "Invalid compatibility level: '%s'\n",
> + buf);
Indentation looks off.
> @@ -1682,7 +1676,7 @@ static int qcow2_create(const char *filename,
> QEMUOptionParameter *options,
> }
>
> ret = qcow2_create2(filename, sectors, backing_file, backing_fmt, flags,
> - cluster_size, prealloc, options, version,
> &local_err);
> + cluster_size, prealloc, opts, version, &local_err);
> if (error_is_set(&local_err)) {
> error_propagate(errp, local_err);
Might conflict with other cleanups that is turning 'if
(error_is_set(&local_err))' into 'if (local_err)'
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- Re: [Qemu-devel] [PATCH v20 05/26] remove assertion of qemu_opt_get functions, (continued)
- [Qemu-devel] [PATCH v20 01/26] add def_value_str to QemuOptDesc, Chunyan Liu, 2014/02/12
- [Qemu-devel] [PATCH v20 06/26] change block layer to support both QemuOpts and QEMUOptionParameter, Chunyan Liu, 2014/02/12
- [Qemu-devel] [PATCH v20 08/26] gluster.c: replace QEMUOptionParameter with QemuOpts, Chunyan Liu, 2014/02/12
- [Qemu-devel] [PATCH v20 07/26] cow.c: replace QEMUOptionParameter with QemuOpts, Chunyan Liu, 2014/02/12
- [Qemu-devel] [PATCH v20 11/26] qcow2.c: replace QEMUOptionParameter with QemuOpts in create, Chunyan Liu, 2014/02/12
- Re: [Qemu-devel] [PATCH v20 11/26] qcow2.c: replace QEMUOptionParameter with QemuOpts in create,
Eric Blake <=
- [Qemu-devel] [PATCH v20 09/26] iscsi.c: replace QEMUOptionParameter with QemuOpts, Chunyan Liu, 2014/02/12
- [Qemu-devel] [PATCH v20 10/26] qcow.c: replace QEMUOptionParameter with QemuOpts, Chunyan Liu, 2014/02/12
- [Qemu-devel] [PATCH v20 12/26] qcow2.c: replace QEMUOptionParameter with QemuOpts in amend options, Chunyan Liu, 2014/02/12
- [Qemu-devel] [PATCH v20 15/26] raw-win32.c: replace QEMUOptionParameter with QemuOpts, Chunyan Liu, 2014/02/12
- [Qemu-devel] [PATCH v20 13/26] qed.c: replace QEMUOptionParameter with QemuOpts, Chunyan Liu, 2014/02/12