aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-sqlite.py
diff options
context:
space:
mode:
authorArnd Bergmann <[email protected]>2018-03-28 16:09:10 +0200
committerSteven Rostedt (VMware) <[email protected]>2018-07-03 18:14:39 -0400
commitcf4d418e653afc84c9c873236033e06be5d58f1c (patch)
treea4b635c35a366aee31cbb33964701ed2faaece5b /tools/perf/scripts/python/export-to-sqlite.py
parent021c91791a5e7e85c567452f1be3e4c2c6cb6063 (diff)
tracing: Avoid string overflow
'err' is used as a NUL-terminated string, but using strncpy() with the length equal to the buffer size may result in lack of the termination: kernel/trace/trace_events_hist.c: In function 'hist_err_event': kernel/trace/trace_events_hist.c:396:3: error: 'strncpy' specified bound 256 equals destination size [-Werror=stringop-truncation] strncpy(err, var, MAX_FILTER_STR_VAL); This changes it to use the safer strscpy() instead. Link: http://lkml.kernel.org/r/[email protected] Cc: [email protected] Fixes: f404da6e1d46 ("tracing: Add 'last error' error facility for hist triggers") Acked-by: Tom Zanussi <[email protected]> Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Steven Rostedt (VMware) <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions