aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/util/trace-event-scripting.c
diff options
context:
space:
mode:
authorSteven Rostedt (Google) <[email protected]>2023-07-04 10:08:07 -0400
committerSteven Rostedt (Google) <[email protected]>2023-07-05 10:30:49 -0400
commitfddca7db4a4c17f7333793dfb5308d80c76d2896 (patch)
tree2740268b7b0d3c3e4b0fe0d4ce7bc3f42b2a4b09 /tools/perf/util/trace-event-scripting.c
parent931a2ca6a5ba4bfa6062aa9475d4e6a835d75e83 (diff)
tracing/boot: Test strscpy() against less than zero for error
Instead of checking for -E2BIG, it is better to just check for less than zero of strscpy() for error. Testing for -E2BIG is not very robust, and the calling code does not really care about the error code, just that there was an error. One of the updates to convert strlcpy() to strscpy() had a v2 version that changed the test from testing against -E2BIG to less than zero, but I took the v1 version that still tested for -E2BIG. Link: https://lore.kernel.org/linux-trace-kernel/[email protected]/ Link: https://lore.kernel.org/linux-trace-kernel/[email protected] Cc: Mark Rutland <[email protected]> Cc: Azeem Shaikh <[email protected]> Cc: Kees Cook <[email protected]> Acked-by: Masami Hiramatsu (Google) <[email protected]> Signed-off-by: Steven Rostedt (Google) <[email protected]>
Diffstat (limited to 'tools/perf/util/trace-event-scripting.c')
0 files changed, 0 insertions, 0 deletions