From 355ef4ac95a7a47d5c7201ccd910056a100d2fdf Mon Sep 17 00:00:00 2001 From: Kevin Wolf Date: Wed, 11 Dec 2013 20:14:09 +0100 Subject: block: Update BlockLimits when they might have changed When reopening with different flags, or when backing files disappear from the chain, the limits may change. Make sure they get updated in these cases. Signed-off-by: Kevin Wolf Reviewed-by: Wenchao Xia Reviewed-by: Max Reitz Reviewed-by: BenoƮt Canet --- block/stream.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'block') diff --git a/block/stream.c b/block/stream.c index 46bec7d379..dd0b4ac3d2 100644 --- a/block/stream.c +++ b/block/stream.c @@ -75,6 +75,8 @@ static void close_unused_images(BlockDriverState *top, BlockDriverState *base, unused->backing_hd = NULL; bdrv_unref(unused); } + + bdrv_refresh_limits(top); } static void coroutine_fn stream_run(void *opaque) -- cgit v1.2.3-55-g7522