summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnna Sztukowska <anna.sztukowska@intel.com>2024-06-28 12:32:16 +0200
committerMariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>2024-07-03 12:18:29 +0200
commit44457789fd67168c37932060f9a991f0c611e5a2 (patch)
treed5c6a2d703e9efb3d0327ca142801a21178606e5
parentCI: use prepared checkpatch.conf file only for GH actions (diff)
downloadmdadm-44457789fd67168c37932060f9a991f0c611e5a2.tar.xz
mdadm-44457789fd67168c37932060f9a991f0c611e5a2.zip
config.c: Fix memory leak in load_containers()
Fix memory leak in load_containers() in config.c reported by SAST analysis. Signed-off-by: Anna Sztukowska <anna.sztukowska@intel.com>
-rw-r--r--config.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/config.c b/config.c
index 612e700d..cd2379bd 100644
--- a/config.c
+++ b/config.c
@@ -379,6 +379,7 @@ struct mddev_dev *load_containers(void)
map = NULL;
}
free_mdstat(mdstat);
+ map_free(map);
return rv;
}