linux/tools/perf/util/kvm-stat-arch
Namhyung Kim cd589eba99 perf kvm: Kill STRDUP_FAIL_EXIT()
It's used to pass command line options to a copied argv.  But there's no
reason to make the copies as it's all used in the same function.  It can
simply use stack variables.

In fact, it fixes a subtle double free issue.  As parse_options() can
move contents in argv[], some entries may point to the same item.  So
freeing all items in the argv could trigger a double free.  With stack
variables, we don't need to allocate and free them.

Tested-by: Ian Rogers <irogers@google.com>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
2026-07-03 13:40:24 -07:00
..
arm64_exception_types.h perf kvm stat: Remove use of the arch directory 2026-02-03 18:01:27 -03:00
book3s_hcalls.h perf kvm stat: Remove use of the arch directory 2026-02-03 18:01:27 -03:00
book3s_hv_exits.h perf kvm stat: Add missing mappings for PPC kvm exit reasons 2026-06-30 10:24:22 -07:00
Build perf kvm stat: Remove use of the arch directory 2026-02-03 18:01:27 -03:00
kvm-stat-arm64.c perf evsel: Refactor evsel tracepoint sample accessors perf_sample 2026-05-20 16:35:59 -03:00
kvm-stat-loongarch.c perf evsel: Refactor evsel tracepoint sample accessors perf_sample 2026-05-20 16:35:59 -03:00
kvm-stat-powerpc.c perf kvm: Kill STRDUP_FAIL_EXIT() 2026-07-03 13:40:24 -07:00
kvm-stat-riscv.c perf evsel: Refactor evsel tracepoint sample accessors perf_sample 2026-05-20 16:35:59 -03:00
kvm-stat-s390.c perf evsel: Refactor evsel tracepoint sample accessors perf_sample 2026-05-20 16:35:59 -03:00
kvm-stat-x86.c perf kvm: Kill STRDUP_FAIL_EXIT() 2026-07-03 13:40:24 -07:00
riscv_trap_types.h perf kvm stat: Remove use of the arch directory 2026-02-03 18:01:27 -03:00