From bdb734763bcee8cfe2b6d70944ee4ae75987a6c6 Mon Sep 17 00:00:00 2001 From: Emanuele Giuseppe Esposito Date: Thu, 3 Mar 2022 10:16:02 -0500 Subject: block.c: add assertions to static functions Following the assertion derived from the API split, propagate the assertion also in the static functions. Signed-off-by: Emanuele Giuseppe Esposito Message-Id: <20220303151616.325444-18-eesposit@redhat.com> Signed-off-by: Kevin Wolf --- block/block-backend.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'block/block-backend.c') diff --git a/block/block-backend.c b/block/block-backend.c index 7d2181e..2ab1274 100644 --- a/block/block-backend.c +++ b/block/block-backend.c @@ -767,6 +767,9 @@ BlockDriverState *blk_bs(BlockBackend *blk) static BlockBackend *bdrv_first_blk(BlockDriverState *bs) { BdrvChild *child; + + GLOBAL_STATE_CODE(); + QLIST_FOREACH(child, &bs->parents, next_parent) { if (child->klass == &child_root) { return child->opaque; -- cgit v1.1