summaryrefslogtreecommitdiffstats
path: root/tools/perf/pmu-events/jevents.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2020-09-03 19:10:43 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2020-09-03 19:10:43 -0700
commit59126901f200f5fc907153468b03c64e0081b6e6 (patch)
tree39c95bfd211314f78772e788ab0555bf614f2522 /tools/perf/pmu-events/jevents.c
parent3e8d3bdc2a757cc6be5470297947799a7df445cc (diff)
parent830fadfd954c6782b7a8a2461c76a568c7153b9a (diff)
downloadlinux-stable-59126901f200f5fc907153468b03c64e0081b6e6.tar.gz
linux-stable-59126901f200f5fc907153468b03c64e0081b6e6.tar.bz2
linux-stable-59126901f200f5fc907153468b03c64e0081b6e6.zip
Merge tag 'perf-tools-fixes-for-v5.9-2020-09-03' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux
Pull more perf tools fixes from Arnaldo Carvalho de Melo: - Use uintptr_t when casting numbers to pointers - Keep output expected by 3rd parties: Turn off summary for interval mode by default. - BPF is in kernel space, make sure do_validate_kcore_modules() knows about that. - Explicitly call out event modifiers in the documentation. - Fix jevents() allocation of space for regular expressions. - Address libtraceevent build warnings on 32-bit arches. - Fix checking of functions returns using ERR_PTR() in 'perf bench'. * tag 'perf-tools-fixes-for-v5.9-2020-09-03' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux: perf tools: Add bpf image check to __map__is_kmodule perf record/stat: Explicitly call out event modifiers in the documentation perf bench: The do_run_multi_threaded() function must use IS_ERR(perf_session__new()) perf stat: Turn off summary for interval mode by default libtraceevent: Fix build warning on 32-bit arches perf jevents: Fix suspicious code in fixregex() perf parse-events: Use uintptr_t when casting numbers to pointers
Diffstat (limited to 'tools/perf/pmu-events/jevents.c')
-rw-r--r--tools/perf/pmu-events/jevents.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/pmu-events/jevents.c b/tools/perf/pmu-events/jevents.c
index fa86c5f997cc..fc9c158bfa13 100644
--- a/tools/perf/pmu-events/jevents.c
+++ b/tools/perf/pmu-events/jevents.c
@@ -137,7 +137,7 @@ static char *fixregex(char *s)
return s;
/* allocate space for a new string */
- fixed = (char *) malloc(len + 1);
+ fixed = (char *) malloc(len + esc_count + 1);
if (!fixed)
return NULL;