diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index 8193805b00..c513d46e10 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -41,6 +41,7 @@ #include "qemu_monitor.h" #include "virstring.h" #include "qemu_hostdev.h" +#include "qemu_domain.h" #include #include @@ -3394,7 +3395,7 @@ virQEMUCapsInitQMP(virQEMUCapsPtr qemuCaps, if (monpath) ignore_value(unlink(monpath)); VIR_FREE(monpath); - virObjectUnref(vm); + qemuDomObjEndAPI(&vm); virObjectUnref(xmlopt); if (pid != 0) {