From: Mathieu Desnoyers Date: Mon, 6 Apr 2015 16:16:11 +0000 (-0400) Subject: Fix: zero memory passed to create channel kernel ioctl X-Git-Tag: v2.7.0-rc1~48 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=c74101efbbb06ea591b5c989afa3714689e843bb;p=lttng-tools.git Fix: zero memory passed to create channel kernel ioctl Valgrind complains about uninitialized memory passed to ioctl. Signed-off-by: Mathieu Desnoyers Signed-off-by: Jérémie Galarneau --- diff --git a/src/common/kernel-ctl/kernel-ctl.c b/src/common/kernel-ctl/kernel-ctl.c index 28ed06cbd..18cd95529 100644 --- a/src/common/kernel-ctl/kernel-ctl.c +++ b/src/common/kernel-ctl/kernel-ctl.c @@ -112,6 +112,7 @@ int kernctl_create_channel(int fd, struct lttng_channel_attr *chops) { struct lttng_kernel_channel channel; + memset(&channel, 0, sizeof(channel)); if (lttng_kernel_use_old_abi) { struct lttng_kernel_old_channel old_channel;