[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 06/17] block: expect errors from bdrv_co_is_allo
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [PATCH 06/17] block: expect errors from bdrv_co_is_allocated |
Date: |
Fri, 5 Jul 2013 11:19:50 +0200 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Wed, Jul 03, 2013 at 04:34:20PM +0200, Paolo Bonzini wrote:
> diff --git a/qemu-img.c b/qemu-img.c
> index f8c97d3..857e2ca 100644
> --- a/qemu-img.c
> +++ b/qemu-img.c
> @@ -2073,6 +2073,10 @@ static int img_rebase(int argc, char **argv)
>
> /* If the cluster is allocated, we don't need to take action */
> ret = bdrv_is_allocated(bs, sector, n, &n);
> + if (ret < 0) {
> + error_report("error while reading from file");
> + goto out;
> + }
We should print the errno valid and saying "while reading from file" is
a little misleading:
"error while checking cluster allocation status: %d", ret
- Re: [Qemu-devel] [PATCH 01/17] cow: make reads go at a decent speed, (continued)
- [Qemu-devel] [PATCH 02/17] cow: make writes go at a less indecent speed, Paolo Bonzini, 2013/07/03
- [Qemu-devel] [PATCH 03/17] cow: do not call bdrv_co_is_allocated, Paolo Bonzini, 2013/07/03
- [Qemu-devel] [PATCH 04/17] block: make bdrv_co_is_allocated static, Paolo Bonzini, 2013/07/03
- [Qemu-devel] [PATCH 05/17] block: remove bdrv_is_allocated_above/bdrv_co_is_allocated_above distinction, Paolo Bonzini, 2013/07/03
- [Qemu-devel] [PATCH 07/17] qemu-img: always probe the input image for allocated sectors, Paolo Bonzini, 2013/07/03
- [Qemu-devel] [PATCH 06/17] block: expect errors from bdrv_co_is_allocated, Paolo Bonzini, 2013/07/03
- Re: [Qemu-devel] [PATCH 06/17] block: expect errors from bdrv_co_is_allocated,
Stefan Hajnoczi <=
- [Qemu-devel] [PATCH 08/17] block: make bdrv_has_zero_init return false for copy-on-write-images, Paolo Bonzini, 2013/07/03
- [Qemu-devel] [PATCH 09/17] block: introduce bdrv_get_block_status API, Paolo Bonzini, 2013/07/03
- [Qemu-devel] [PATCH 10/17] block: define get_block_status return value, Paolo Bonzini, 2013/07/03
[Qemu-devel] [PATCH 12/17] qemu-img: add a "map" subcommand, Paolo Bonzini, 2013/07/03