[PATCH 35/36] virt-host-validate-qemu: Use automatic memory freeing for virBitmap

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

 



Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
 tools/virt-host-validate-qemu.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/tools/virt-host-validate-qemu.c b/tools/virt-host-validate-qemu.c
index d225a7e5c8..46ff1d2494 100644
--- a/tools/virt-host-validate-qemu.c
+++ b/tools/virt-host-validate-qemu.c
@@ -29,7 +29,7 @@

 int virHostValidateQEMU(void)
 {
-    virBitmap *flags;
+    g_autoptr(virBitmap) flags = NULL;
     int ret = 0;
     bool hasHwVirt = false;
     bool hasVirtFlag = false;
@@ -98,8 +98,6 @@ int virHostValidateQEMU(void)
             virHostMsgPass();
     }

-    virBitmapFree(flags);
-
     if (virHostValidateDeviceExists("QEMU", "/dev/vhost-net",
                                     VIR_HOST_VALIDATE_WARN,
                                     _("Load the 'vhost_net' module to improve performance "
-- 
2.31.1




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux