Am 19.05.2016 um 03:25 hat Fam Zheng geschrieben:
> Otherwise the job is orphaned and block_job_cancel_sync in
> bdrv_close_all() when quitting will trigger assertion failure.
> 
> Cc: [email protected]
> Reviewed-by: John Snow <[email protected]>
> Reviewed-by: Jeff Cody <[email protected]>
> Signed-off-by: Fam Zheng <[email protected]>

Instead of moving the code around, wouldn't it have been easier to just
add the missing block_job_unref() call? That would also seem safer with
respect to future changes in the code that might reintroduce new error
conditions after block_job_create() and resurrect this bug.

That said, the patch looks correct, so if you don't want to change it:

Reviewed-by: Kevin Wolf <[email protected]>

Reply via email to