qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v4 03/16] block: Add Error parameter to bdrv_fin


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v4 03/16] block: Add Error parameter to bdrv_find_protocol()
Date: Thu, 05 Feb 2015 13:15:05 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0

On 02/05/2015 11:58 AM, Max Reitz wrote:
> The argument given to bdrv_find_protocol() is just a file name, which
> makes it difficult for the caller to reconstruct what protocol
> bdrv_find_protocol() was hoping to find. This patch adds an Error
> parameter to that function to solve this issue.
> 
> Suggested-by: Eric Blake <address@hidden>
> Signed-off-by: Max Reitz <address@hidden>
> ---
>  block.c                    | 14 +++++++-------
>  block/sheepdog.c           |  2 +-
>  include/block/block.h      |  3 ++-
>  qemu-img.c                 | 11 +++++++----
>  tests/qemu-iotests/051.out |  4 ++--
>  5 files changed, 19 insertions(+), 15 deletions(-)
> 

>  Testing: -hda foo:bar
> -QEMU_PROG: -hda foo:bar: could not open disk image foo:bar: Unknown protocol
> +QEMU_PROG: -hda foo:bar: could not open disk image foo:bar: Unknown protocol 
> 'foo'
>  

Indeed a nicer message.

Reviewed-by: Eric Blake <address@hidden>

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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