summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorDouglas Raillard <douglas.raillard@arm.com>2025-03-25 16:52:02 +0000
committerSteven Rostedt (Google) <rostedt@goodmis.org>2025-03-25 17:42:38 -0400
commit4d38328eb442dc06aec4350fd9594ffa6488af02 (patch)
tree48da9780c214d5c1b2055ff62af7e76f582b56cc /tools/perf/scripts/python/stackcollapse.py
parent8eb1518642738c6892bd629b46043513a3bf1a6a (diff)
downloadlwn-4d38328eb442dc06aec4350fd9594ffa6488af02.tar.gz
lwn-4d38328eb442dc06aec4350fd9594ffa6488af02.zip
tracing: Fix synth event printk format for str fields
The printk format for synth event uses "%.*s" to print string fields, but then only passes the pointer part as var arg. Replace %.*s with %s as the C string is guaranteed to be null-terminated. The output in print fmt should never have been updated as __get_str() handles the string limit because it can access the length of the string in the string meta data that is saved in the ring buffer. Cc: stable@vger.kernel.org Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com> Fixes: 8db4d6bfbbf92 ("tracing: Change synthetic event string format to limit printed length") Link: https://lore.kernel.org/20250325165202.541088-1-douglas.raillard@arm.com Signed-off-by: Douglas Raillard <douglas.raillard@arm.com> Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions