From: Mathieu Desnoyers Date: Fri, 4 Sep 2015 05:12:53 +0000 (-0400) Subject: Fix: use after free in channel release X-Git-Tag: v2.6.3~1 X-Git-Url: https://git.lttng.org/?p=lttng-modules.git;a=commitdiff_plain;h=afbb7f1f732082fea302d5c821b8b67fae445e2b Fix: use after free in channel release Signed-off-by: Mathieu Desnoyers --- diff --git a/lttng-abi.c b/lttng-abi.c index 6993a46f..bdc6c766 100644 --- a/lttng-abi.c +++ b/lttng-abi.c @@ -1234,8 +1234,8 @@ int lttng_metadata_channel_release(struct inode *inode, struct file *file) struct lttng_channel *channel = file->private_data; if (channel) { - lttng_metadata_channel_destroy(channel); fput(channel->session->file); + lttng_metadata_channel_destroy(channel); } return 0;