Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-15-SP1:GA
perf.12208
perf-trace-fix-off-by-one-string-allocation-pro...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File perf-trace-fix-off-by-one-string-allocation-problem.patch of Package perf.12208
From: Arnaldo Carvalho de Melo <acme@redhat.com> Date: Thu, 17 Aug 2017 15:12:55 -0300 Subject: perf trace: Fix off by one string allocation problem Git-commit: d6d4fc6fefda26a88eb99d30e87a8834c59c144a Patch-mainline: v4.14-rc1 References: bsc#1070010 (git-fixes) Signed-off-By: Tony Jones <tonyj@suse.de> We need to consider the null terminator, oops, fix it. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Fixes: 017037ff3d0b ("perf trace: Allow specifying list of syscalls and events in -e/--expr/--event") Link: http://lkml.kernel.org/n/tip-j79jpqqe91gvxqmsgxgfn2ni@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> --- tools/perf/builtin-trace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c index de02413a25d3..91905839e386 100644 --- a/tools/perf/builtin-trace.c +++ b/tools/perf/builtin-trace.c @@ -2806,7 +2806,7 @@ static int trace__parse_events_option(const struct option *opt, const char *str, struct trace *trace = (struct trace *)opt->value; const char *s = str; char *sep = NULL, *lists[2] = { NULL, NULL, }; - int len = strlen(str), err = -1, list; + int len = strlen(str) + 1, err = -1, list; char *strace_groups_dir = system_path(STRACE_GROUPS_DIR); char group_name[PATH_MAX];
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor