]> Git Repo - linux.git/blobdiff - tools/perf/util/help.c
perf tools: Use zfree to help detect use after free bugs
[linux.git] / tools / perf / util / help.c
index 7b68978e50d24d98c7da185c606ca8e8b9be8a3a..86c37c472263568bdc1cfe24458653c535da9a87 100644 (file)
@@ -22,8 +22,8 @@ static void clean_cmdnames(struct cmdnames *cmds)
        unsigned int i;
 
        for (i = 0; i < cmds->cnt; ++i)
-               free(cmds->names[i]);
-       free(cmds->names);
+               zfree(&cmds->names[i]);
+       zfree(&cmds->names);
        cmds->cnt = 0;
        cmds->alloc = 0;
 }
This page took 0.031133 seconds and 4 git commands to generate.