Signed-off-by: Ján Tomko <jtomko@xxxxxxxxxx> --- src/qemu/qemu_command.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index e47f30876e..a4df133ca0 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -6900,7 +6900,7 @@ qemuBuildCpuModelArgStr(virQEMUDriverPtr driver, { int ret = -1; size_t i; - virCapsPtr caps = NULL; + VIR_AUTOUNREF(virCapsPtr) caps = NULL; virCPUDefPtr cpu = def->cpu; if (!(caps = virQEMUDriverGetCapabilities(driver, false))) @@ -6978,7 +6978,6 @@ qemuBuildCpuModelArgStr(virQEMUDriverPtr driver, ret = 0; cleanup: - virObjectUnref(caps); return ret; } @@ -8486,7 +8485,7 @@ qemuInterfaceVhostuserConnect(virQEMUDriverPtr driver, virQEMUCapsPtr qemuCaps, char **chardev) { - virQEMUDriverConfigPtr cfg = virQEMUDriverGetConfig(driver); + VIR_AUTOUNREF(virQEMUDriverConfigPtr) cfg = virQEMUDriverGetConfig(driver); int ret = -1; switch ((virDomainChrType)net->data.vhostuser->type) { @@ -8519,7 +8518,6 @@ qemuInterfaceVhostuserConnect(virQEMUDriverPtr driver, ret = 0; cleanup: - virObjectUnref(cfg); return ret; } -- 2.19.2 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list