Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ee474b81 authored by Masami Hiramatsu's avatar Masami Hiramatsu Committed by Steven Rostedt (VMware)
Browse files

tracing/kprobes: Fix strpbrk() argument order

Fix strpbrk()'s argument order, it must pass acceptable string
in 2nd argument. Note that this can cause a kernel panic where
it recovers backup character to code->data.

Link: http://lkml.kernel.org/r/154108256792.2604.1816052586385217811.stgit@devbox



Fixes: a6682814 ("tracing/kprobes: Allow kprobe-events to record module symbol")
Signed-off-by: default avatarMasami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: default avatarSteven Rostedt (VMware) <rostedt@goodmis.org>
parent 65102238
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -535,7 +535,7 @@ int traceprobe_update_arg(struct probe_arg *arg)
			if (code[1].op != FETCH_OP_IMM)
				return -EINVAL;

			tmp = strpbrk("+-", code->data);
			tmp = strpbrk(code->data, "+-");
			if (tmp)
				c = *tmp;
			ret = traceprobe_split_symbol_offset(code->data,