qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCHv6] add qemu-img convert -n option (skip target v


From: Alex Bligh
Subject: Re: [Qemu-devel] [PATCHv6] add qemu-img convert -n option (skip target volume creation)
Date: Mon, 2 Sep 2013 19:08:54 +0100

On 2 Sep 2013, at 16:28, Stefan Hajnoczi wrote:

> If bdrv_getlength() failed and bdrv_get_geometry() produced a 0 result,
> then this error message will be confusing to users.
> 
> It would be better to use bdrv_getlength() directly:
> 
> int64_t length = bdrv_getlength(out_bs);
> if (length < 0) {
>    error_report("unable to get output image length: %s\n", strerror(-length));
>    ret = -1;
>    goto out;
> } else if (length < total_sectors) {
>    error_report("output file is smaller than input file");
>    ret = -1;
>    goto out;
> }

Fixed in v7 (just sent) subject to fixing the deliberate
mistake in the above :-)

Other two fixed too.

-- 
Alex Bligh







reply via email to

[Prev in Thread] Current Thread [Next in Thread]