From: Mathieu Desnoyers Date: Sat, 21 May 2011 17:08:26 +0000 (-0400) Subject: Fix metadata event arg (null pointer exception) X-Git-Tag: v2.0-pre1~128 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=e70a4758e5d5b11aca964eb36d1d2258c97105af;p=lttng-modules.git Fix metadata event arg (null pointer exception) Signed-off-by: Mathieu Desnoyers --- diff --git a/ltt-debugfs-abi.c b/ltt-debugfs-abi.c index 80fecbe9..02f7232c 100644 --- a/ltt-debugfs-abi.c +++ b/ltt-debugfs-abi.c @@ -142,6 +142,10 @@ static void lttng_metadata_create_events(struct file *channel_file) { struct ltt_channel *channel = channel_file->private_data; + static struct lttng_kernel_event metadata_params = { + .instrumentation = LTTNG_KERNEL_TRACEPOINTS, + .name = "lttng_metadata", + }; char *event_name = "lttng_metadata"; struct ltt_event *event; int ret; @@ -150,8 +154,7 @@ void lttng_metadata_create_events(struct file *channel_file) * We tolerate no failure path after event creation. It will stay * invariant for the rest of the session. */ - event = ltt_event_create(channel, event_name, LTTNG_KERNEL_TRACEPOINTS, - NULL); + event = ltt_event_create(channel, event_name, &metadata_params, NULL); if (!event) { goto create_error; ret = -EEXIST;