mirror of https://gitee.com/openkylin/libvirt.git
libxl: add missing cleanup on error path in libxlDomainPMWakeup
Since domain was suspended before and on failed wakeup is destroyed, send an event. Also, add missing libxlDomainCleanup. Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com> Reviewed-by: Jim Fehlig <jfehlig@suse.com>
This commit is contained in:
parent
c55ff370f8
commit
73dfa2cf74
|
@ -1527,6 +1527,9 @@ libxlDomainPMWakeup(virDomainPtr dom, unsigned int flags)
|
|||
libxlDomainDestroyInternal(driver, vm);
|
||||
vm->def->id = -1;
|
||||
virDomainObjSetState(vm, VIR_DOMAIN_SHUTOFF, VIR_DOMAIN_SHUTOFF_FAILED);
|
||||
event = virDomainEventLifecycleNewFromObj(vm, VIR_DOMAIN_EVENT_STOPPED,
|
||||
VIR_DOMAIN_EVENT_STOPPED_FAILED);
|
||||
libxlDomainCleanup(driver, vm);
|
||||
|
||||
endjob:
|
||||
libxlDomainObjEndJob(driver, vm);
|
||||
|
|
Loading…
Reference in New Issue