summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2026-07-26 20:40:13 -0300
committerNamhyung Kim <namhyung@kernel.org>2026-07-31 16:42:17 -0700
commitf53bf58dcd11e1cb088d3b91a035fef77062094b (patch)
tree2c3bee1b6aca5f163ec59303f150b0019bc4da26 /scripts
parent29ec46e43f6ca7d6a6651db724d4ffd820f46e8b (diff)
downloadlinux-f53bf58dcd11e1cb088d3b91a035fef77062094b.tar.gz
linux-f53bf58dcd11e1cb088d3b91a035fef77062094b.zip
perf machine: Free scandir entries in guest kernel map creation
machines__create_guest_kernel_maps() calls scandir() which allocates both the namelist array and each individual dirent entry. The code frees the namelist array but not the individual entries, leaking memory proportional to the number of directories under guestmount. Free each namelist[i] after it is no longer needed. Fixes: a1645ce12adb ("perf: 'perf kvm' tool for monitoring guest performance from host") Reported-by: sashiko-bot <sashiko-bot@kernel.org> Cc: Zhang, Yanmin <yanmin_zhang@linux.intel.com> Assisted-by: Claude:claude-opus-4.6 Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions