render / rpms / libvirt

Forked from rpms/libvirt 10 months ago
Clone
8c03ec
From 7cdf83f2e699a9c9b8cafbc09dbd21d2cb3a3b45 Mon Sep 17 00:00:00 2001
8c03ec
Message-Id: <7cdf83f2e699a9c9b8cafbc09dbd21d2cb3a3b45@dist-git>
8c03ec
From: Pavel Hrdina <phrdina@redhat.com>
8c03ec
Date: Fri, 19 Feb 2021 13:34:01 +0100
8c03ec
Subject: [PATCH] vircgroup: correctly free nested virCgroupPtr
8c03ec
MIME-Version: 1.0
8c03ec
Content-Type: text/plain; charset=UTF-8
8c03ec
Content-Transfer-Encoding: 8bit
8c03ec
8c03ec
Fixes: 184245f53b94fc84f727eb6e8a2aa52df02d69c0
8c03ec
8c03ec
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
8c03ec
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
8c03ec
(cherry picked from commit 6a1f5e8a4f3184bb54b9dcaa3afcf8c97adccb62)
8c03ec
8c03ec
Conflicts:
8c03ec
    src/util/vircgroup.c
8c03ec
        - missing upstream g_free rewrite
8c03ec
8c03ec
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1798463
8c03ec
8c03ec
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
8c03ec
Message-Id: <bc2f0207bc684ca81c45b6234a7aaba5227867d7.1613737828.git.phrdina@redhat.com>
8c03ec
Reviewed-by: Ján Tomko <jtomko@redhat.com>
8c03ec
---
8c03ec
 src/util/vircgroup.c | 3 ++-
8c03ec
 1 file changed, 2 insertions(+), 1 deletion(-)
8c03ec
8c03ec
diff --git a/src/util/vircgroup.c b/src/util/vircgroup.c
8c03ec
index d0f867ba7f..0a6404e97c 100644
8c03ec
--- a/src/util/vircgroup.c
8c03ec
+++ b/src/util/vircgroup.c
8c03ec
@@ -3711,7 +3711,8 @@ virCgroupFree(virCgroupPtr *group)
8c03ec
     VIR_FREE((*group)->unified.mountPoint);
8c03ec
     VIR_FREE((*group)->unified.placement);
8c03ec
     VIR_FREE((*group)->unitName);
8c03ec
-    VIR_FREE((*group)->nested);
8c03ec
+
8c03ec
+    virCgroupFree(&(*group)->nested);
8c03ec
 
8c03ec
     VIR_FREE((*group)->path);
8c03ec
     VIR_FREE(*group);
8c03ec
-- 
8c03ec
2.30.0
8c03ec