char *m is allocated by xstrdup but not free() before return, will cause a memory leak Signed-off-by: Wu Guanghao <wuguanghao3@xxxxxxxxxx> --- util.c | 1 + 1 file changed, 1 insertion(+) diff --git a/util.c b/util.c index cc94f96e..da18a68d 100644 --- a/util.c +++ b/util.c @@ -429,6 +429,7 @@ int parse_layout_faulty(char *layout) int mode; m[ln] = 0; mode = map_name(faultylayout, m); + free(m); if (mode == UnSet) return -1; -- 2.27.0