From: Vladimir Sementsov-Ogievskiy <[email protected]> We don't have bdrv_replace_child(), so it's time for bdrv_replace_child_safe() to take its place.
Signed-off-by: Vladimir Sementsov-Ogievskiy <[email protected]> Reviewed-by: Kevin Wolf <[email protected]> Message-Id: <[email protected]> Signed-off-by: Kevin Wolf <[email protected]> --- block.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/block.c b/block.c index 7b2a8844f6..df8fa6003c 100644 --- a/block.c +++ b/block.c @@ -2248,12 +2248,12 @@ static TransactionActionDrv bdrv_replace_child_drv = { }; /* - * bdrv_replace_child_safe + * bdrv_replace_child * * Note: real unref of old_bs is done only on commit. */ -static void bdrv_replace_child_safe(BdrvChild *child, BlockDriverState *new_bs, - Transaction *tran) +static void bdrv_replace_child(BdrvChild *child, BlockDriverState *new_bs, + Transaction *tran) { BdrvReplaceChildState *s = g_new(BdrvReplaceChildState, 1); *s = (BdrvReplaceChildState) { @@ -4803,7 +4803,7 @@ static void bdrv_remove_filter_or_cow_child(BlockDriverState *bs, } if (child->bs) { - bdrv_replace_child_safe(child, NULL, tran); + bdrv_replace_child(child, NULL, tran); } s = g_new(BdrvRemoveFilterOrCowChild, 1); @@ -4843,7 +4843,7 @@ static int bdrv_replace_node_noperm(BlockDriverState *from, c->name, from->node_name); return -EPERM; } - bdrv_replace_child_safe(c, to, tran); + bdrv_replace_child(c, to, tran); } return 0; -- 2.30.2
