]> git.proxmox.com Git - mirror_qemu.git/commit
commit: Fix completion with extra reference
authorKevin Wolf <kwolf@redhat.com>
Fri, 9 Jun 2017 11:29:36 +0000 (13:29 +0200)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Thu, 24 Aug 2017 21:53:45 +0000 (16:53 -0500)
commit1dd3ba38f6ebf5c11194b420c0539c05cfed1f51
tree5ec730079e3cba4f9a5ce30232e65bbbfb1e9322
parentecc7a24c11e2ef0ea5965af36bc0aca833435141
commit: Fix completion with extra reference

commit_complete() can't assume that after its block_job_completed() the
job is actually immediately freed; someone else may still be holding
references. In this case, the op blockers on the intermediate nodes make
the graph reconfiguration in the completion code fail.

Call block_job_remove_all_bdrv() manually so that we know for sure that
any blockers on intermediate nodes are given up.

Cc: qemu-stable@nongnu.org
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
(cherry picked from commit 4f78a16fee462471416dc49b409d57b2071cf3d9)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
block/commit.c