mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-11 23:37:42 +00:00
openvzDomainCreateWithFlags: set domain id to the correct value
When an openvz domain is defined with virDomainDefineXML, domain id is set to -1. A call to virDomainGetInfo after starting the domain would then fail because this invalid id is passed to openvzGetProcessInfo.
This commit is contained in:
parent
549b839960
commit
fd81a09729
@ -992,6 +992,7 @@ openvzDomainCreateWithFlags(virDomainPtr dom, unsigned int flags)
|
|||||||
|
|
||||||
vm->pid = strtoI(vm->def->name);
|
vm->pid = strtoI(vm->def->name);
|
||||||
vm->def->id = vm->pid;
|
vm->def->id = vm->pid;
|
||||||
|
dom->id = vm->pid;
|
||||||
vm->state = VIR_DOMAIN_RUNNING;
|
vm->state = VIR_DOMAIN_RUNNING;
|
||||||
ret = 0;
|
ret = 0;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user