diff --git a/block/block-backend.c b/block/block-backend.c index f71fdb4315..551e4e1708 100644 --- a/block/block-backend.c +++ b/block/block-backend.c @@ -1339,8 +1339,8 @@ static const AIOCBInfo blk_aio_em_aiocb_info = { static void blk_aio_complete(BlkAioEmAIOCB *acb) { if (acb->has_returned) { - blk_dec_in_flight(acb->rwco.blk); acb->common.cb(acb->common.opaque, acb->rwco.ret); + blk_dec_in_flight(acb->rwco.blk); qemu_aio_unref(acb); } }