mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-10 23:07:44 +00:00
qemu: driver: Don't use qemuBlockJobStartupFinalize in processBlockJobEvent
While this function does start a block job in case when we'd not be able to get our internal data for it, the handler sets the job state to QEMU_BLOCKJOB_STATE_RUNNING anyways, thus qemuBlockJobStartupFinalize would just unref the job. Since the other usage of qemuBlockJobStartupFinalize in the other part of the event handler was a bug replace this one anyways even if it would not cause problems. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
00c4c971fd
commit
d26f3cdedd
@ -4686,7 +4686,7 @@ processBlockJobEvent(virQEMUDriverPtr driver,
|
||||
int status)
|
||||
{
|
||||
virDomainDiskDefPtr disk;
|
||||
qemuBlockJobDataPtr job = NULL;
|
||||
VIR_AUTOUNREF(qemuBlockJobDataPtr) job = NULL;
|
||||
|
||||
if (qemuDomainObjBeginJob(driver, vm, QEMU_JOB_MODIFY) < 0)
|
||||
return;
|
||||
@ -4712,7 +4712,6 @@ processBlockJobEvent(virQEMUDriverPtr driver,
|
||||
qemuBlockJobUpdate(vm, job, QEMU_ASYNC_JOB_NONE);
|
||||
|
||||
endjob:
|
||||
qemuBlockJobStartupFinalize(vm, job);
|
||||
qemuDomainObjEndJob(driver, vm);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user