[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] [PATCH trivial] qemu_conf.c: removing unused virQEMUDriverConfigPtr variable



'virQEMUDriverConfigPtr cfg' is declared, initiated, but never
used in virQEMUDriverCreateCapabilities().

Signed-off-by: Daniel Henrique Barboza <danielhb413 gmail com>
---

Accidental discovery while reading code.

 src/qemu/qemu_conf.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c
index 89c183e46a..d771bb6916 100644
--- a/src/qemu/qemu_conf.c
+++ b/src/qemu/qemu_conf.c
@@ -1266,7 +1266,6 @@ virCapsPtr virQEMUDriverCreateCapabilities(virQEMUDriverPtr driver)
     virSecurityManagerPtr *sec_managers = NULL;
     /* Security driver data */
     const char *doi, *model, *lbl, *type;
-    virQEMUDriverConfigPtr cfg = virQEMUDriverGetConfig(driver);
     const int virtTypes[] = {VIR_DOMAIN_VIRT_KVM,
                              VIR_DOMAIN_VIRT_QEMU,};
 
@@ -1313,13 +1312,11 @@ virCapsPtr virQEMUDriverCreateCapabilities(virQEMUDriverPtr driver)
     }
     VIR_FREE(sec_managers);
 
-    virObjectUnref(cfg);
     return caps;
 
  error:
     VIR_FREE(sec_managers);
     virObjectUnref(caps);
-    virObjectUnref(cfg);
     return NULL;
 }
 
-- 
2.21.0


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]