diff options
| author | Wang Nan <[email protected]> | 2015-09-01 03:29:44 +0000 |
|---|---|---|
| committer | Arnaldo Carvalho de Melo <[email protected]> | 2015-09-01 14:33:48 +0000 |
| commit | 3b27d13940c3710a1128527c43719cb0bb05d73b (patch) | |
| tree | 88847c3a13e7c792c0416be0c6186d903fb57d2c /tools/perf/util/scripting-engines/trace-event-perl.c | |
| parent | Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/... (diff) | |
| download | kernel-3b27d13940c3710a1128527c43719cb0bb05d73b.tar.gz kernel-3b27d13940c3710a1128527c43719cb0bb05d73b.zip | |
perf dwarf: Fix potential array out of bounds access
There is a problem in the dwarf-regs.c files for sh, sparc and x86 where
it is possible to make an out-of-bounds array access when searching for
register names.
This patch fixes it by replacing '<=' to '<', so when register (number
== XXX_MAX_REGS), get_arch_regstr() will return NULL.
Signed-off-by: Wang Nan <[email protected]>
Reviewed-by: Matt Fleming <[email protected]>
Acked-by: Jiri Olsa <[email protected]>
Acked-by: Masami Hiramatsu <[email protected]>
Cc: David S. Miller <[email protected]>
Cc: Zefan Li <[email protected]>
Cc: [email protected]
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-perl.c')
0 files changed, 0 insertions, 0 deletions
