From 8ad6e3bc6d3e9e55093b546ee886a2a2d9e875f5 Mon Sep 17 00:00:00 2001 Message-Id: <8ad6e3bc6d3e9e55093b546ee886a2a2d9e875f5@dist-git> From: Michal Privoznik Date: Fri, 21 May 2021 14:16:13 +0200 Subject: [PATCH] domain_conf: Don't leak def->os.firmwareFeatures The firmwareFeatures member of virDomainOSDef struct is allocated in virDomainDefParseBootFirmwareOptions() but never freed. Signed-off-by: Michal Privoznik Reviewed-by: Pavel Hrdina (cherry picked from commit c116b9481426f86188c71f340d5e3db103120bf8) Conflicts: src/conf/domain_conf.c - missing upstream commits: 77f8e48fc35eaf867eae4f623e381f87f6e29930 f9f81f1c8f855b8c21aeae4441abfc877ff2bfc3 Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1929357 Signed-off-by: Pavel Hrdina Message-Id: <82f4beea71e682c43ec10370d5a43a608d1cb411.1621599207.git.phrdina@redhat.com> Reviewed-by: Michal Privoznik --- src/conf/domain_conf.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 28c8d0ecbd..2ffa9c8a2a 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -3431,6 +3431,7 @@ void virDomainDefFree(virDomainDefPtr def) VIR_FREE(def->idmap.uidmap); VIR_FREE(def->idmap.gidmap); + VIR_FREE(def->os.firmwareFeatures); VIR_FREE(def->os.machine); VIR_FREE(def->os.init); for (i = 0; def->os.initargv && def->os.initargv[i]; i++) -- 2.31.1