diff mbox

[PULL,1/2] block/mirror: fix broken sparseness detection

Message ID 20170228043707.23121-2-jcody@redhat.com (mailing list archive)
State New, archived
Headers show

Commit Message

Jeff Cody Feb. 28, 2017, 4:37 a.m. UTC
From: John Snow <jsnow@redhat.com>

int64_t is in all likelihood the actual scalar type we want.
Yep, really.

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1219541

Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Jeff Cody <jcody@redhat.com>
Signed-off-by: Jeff Cody <jcody@redhat.com>
---
 block/mirror.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/block/mirror.c b/block/mirror.c
index 3d50857..1b34b36 100644
--- a/block/mirror.c
+++ b/block/mirror.c
@@ -386,7 +386,7 @@  static uint64_t coroutine_fn mirror_iteration(MirrorBlockJob *s)
                             nb_chunks * sectors_per_chunk);
     bitmap_set(s->in_flight_bitmap, sector_num / sectors_per_chunk, nb_chunks);
     while (nb_chunks > 0 && sector_num < end) {
-        int ret;
+        int64_t ret;
         int io_sectors, io_sectors_acct;
         BlockDriverState *file;
         enum MirrorMethod {