]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu: Do not try to set memlock on inactive domain
authorJiri Denemark <jdenemar@redhat.com>
Wed, 3 Aug 2022 11:25:06 +0000 (13:25 +0200)
committerJiri Denemark <jdenemar@redhat.com>
Wed, 3 Aug 2022 13:53:57 +0000 (15:53 +0200)
commitfc8538157ba39cffddf29c0ea6983896720c3089
tree3fd8df46f6f5aa1473915b72b2681a8ed467229a
parentf931079e89fb678ed954cba687d43355b7ddcebb
qemu: Do not try to set memlock on inactive domain

When we call qemuDomainSetMaxMemLock to reset memory locking limit back
to its original value the domain can already be stopped (for example
after the domain shuts down during migration) in which case it does not
make sense to set any limit. Doing so can even be harmful as we may end
up setting the limit for the daemon itself as the PID is 0.

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
src/qemu/qemu_domain.c