From: Mathieu Desnoyers Date: Tue, 24 May 2011 14:17:08 +0000 (-0400) Subject: Fix ftrace integration X-Git-Tag: v2.0-pre1~100 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=8a58609868bb8e20dc93478714805e8c3126bd9b;p=lttng-modules.git Fix ftrace integration Signed-off-by: Mathieu Desnoyers --- diff --git a/probes/lttng-ftrace.c b/probes/lttng-ftrace.c index 7637e4b5..5b4cf2e7 100644 --- a/probes/lttng-ftrace.c +++ b/probes/lttng-ftrace.c @@ -118,7 +118,7 @@ int lttng_ftrace_register(const char *name, if (ret) goto error; - event->u.ftrace.symbol_name = kstrdup(name, GFP_KERNEL); + event->u.ftrace.symbol_name = kstrdup(symbol_name, GFP_KERNEL); if (!event->u.ftrace.symbol_name) goto name_error; @@ -127,7 +127,7 @@ int lttng_ftrace_register(const char *name, ret = wrapper_register_ftrace_function_probe(event->u.ftrace.symbol_name, <tng_ftrace_ops, event); - if (ret) + if (ret < 0) goto register_error; return 0;