]> Gentwo Git Trees - linux/.git/commit
perf tools kvm: Fix the potential out of range memory access issue
authorDapeng Mi <dapeng1.mi@linux.intel.com>
Fri, 19 Sep 2025 02:16:56 +0000 (10:16 +0800)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 2 Oct 2025 18:31:00 +0000 (15:31 -0300)
commit45ff39f6e70aa55d0054fbc3508eba9ac03d7e29
tree49129afe8b04b0f9e2557c1e4a88617e4afa935a
parent6f58cf10457f5868ef4cd98b4de6428787b3fb2c
perf tools kvm: Fix the potential out of range memory access issue

kvm_add_default_arch_event() helper may add 2 extra options but it
directly modifies the original argv[] array. This may cause out of range
memory access. Fix this issue.

Signed-off-by: Dapeng Mi <dapeng1.mi@linux.intel.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Kan Liang <kan.liang@linux.intel.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-kvm.c