Commit d0a49706 authored by Tom Zanussi's avatar Tom Zanussi Committed by Steven Rostedt (VMware)

tracing: Add 'hist:' to hist trigger error log error string

The 'hist:' prefix gets stripped from the command text during command
processing, but should be added back when displaying the command
during error processing.

Not only because it's what should be displayed but also because not
having it means the test cases fail because the caret is miscalculated
by the length of the prefix string.

Link: http://lkml.kernel.org/r/449df721f560042e22382f67574bcc5b4d830d3d.1561743018.git.zanussi@kernel.orgReviewed-by: default avatarMasami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: default avatarTom Zanussi <zanussi@kernel.org>
Signed-off-by: default avatarSteven Rostedt (VMware) <rostedt@goodmis.org>
parent 4de26c8c
...@@ -612,7 +612,8 @@ static void last_cmd_set(struct trace_event_file *file, char *str) ...@@ -612,7 +612,8 @@ static void last_cmd_set(struct trace_event_file *file, char *str)
if (!str) if (!str)
return; return;
strncpy(last_cmd, str, MAX_FILTER_STR_VAL - 1); strcpy(last_cmd, "hist:");
strncat(last_cmd, str, MAX_FILTER_STR_VAL - 1 - sizeof("hist:"));
if (file) { if (file) {
call = file->event_call; call = file->event_call;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment