aboutsummaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorMax Reitz <mreitz@redhat.com>2020-06-23 11:29:04 +0200
committerKevin Wolf <kwolf@redhat.com>2020-09-07 12:31:31 +0200
commitc6f6d8462cecda0b9c390831904f1346c01f75ee (patch)
tree3baf21d7eba54696af1397e94f999a969a5dcee2 /block
parent0a7585dbba2bd28f3797ca414c82e526d9814ab1 (diff)
block-copy: Use CAF to find sync=top base
Signed-off-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com> Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block')
-rw-r--r--block/block-copy.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/block/block-copy.c b/block/block-copy.c
index a30b9097ef..cd9bc47c8f 100644
--- a/block/block-copy.c
+++ b/block/block-copy.c
@@ -440,8 +440,8 @@ static int block_copy_block_status(BlockCopyState *s, int64_t offset,
BlockDriverState *base;
int ret;
- if (s->skip_unallocated && s->source->bs->backing) {
- base = s->source->bs->backing->bs;
+ if (s->skip_unallocated) {
+ base = bdrv_backing_chain_next(s->source->bs);
} else {
base = NULL;
}