perf build-id: Ensure struct build_id is empty before use
authorIan Rogers <irogers@google.com>
Thu, 24 Jul 2025 16:32:45 +0000 (09:32 -0700)
committerNamhyung Kim <namhyung@kernel.org>
Fri, 25 Jul 2025 17:37:55 +0000 (10:37 -0700)
commiteee4b66105a6fa3b85fe5260d3791d607570ba95
treed521b4d521e5091033baa765ca819fc03e7526ad
parent29be60c93d2d9300571230edaa484930cdbec437
perf build-id: Ensure struct build_id is empty before use

If a build ID is read then not all code paths may ensure it is empty
before use. Initialize the build_id to be zero-ed unless there is
clear initialization such as a call to build_id__init.

Signed-off-by: Ian Rogers <irogers@google.com>
Link: https://lore.kernel.org/r/20250724163302.596743-6-irogers@google.com
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
tools/perf/bench/inject-buildid.c
tools/perf/builtin-buildid-cache.c
tools/perf/tests/pe-file-parsing.c
tools/perf/tests/sdt.c
tools/perf/util/build-id.c
tools/perf/util/debuginfo.c
tools/perf/util/probe-event.c
tools/perf/util/probe-finder.c
tools/perf/util/symbol-minimal.c
tools/perf/util/symbol.c
tools/perf/util/synthetic-events.c