mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-05 13:17:51 +03:00
libxl: MigratePerform: properly cleanup after libxlDomObjFromDomain
libxlDomObjFromDomain to returns locked and ref counted virDomainObj but libxlDomainMigratePerform3Params only unlocks the object on exit. Convert it to use the virDomainObjEndAPI function for cleanup. Signed-off-by: Jim Fehlig <jfehlig@suse.com> Reviewed-by: John Ferlan <jferlan@redhat.com>
This commit is contained in:
parent
99486799c3
commit
f5eacf2a9a
@ -6097,8 +6097,7 @@ libxlDomainMigratePerform3Params(virDomainPtr dom,
|
||||
ret = 0;
|
||||
|
||||
cleanup:
|
||||
if (vm)
|
||||
virObjectUnlock(vm);
|
||||
virDomainObjEndAPI(&vm);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user