From: Jérémie Galarneau Date: Thu, 22 Apr 2021 23:54:47 +0000 (-0400) Subject: Fix: consumerd: strlen called on uninitialized path X-Git-Tag: v2.11.7~7 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=24cfac94e15895ca56dc4cfb56645bc88c996afe;p=lttng-tools.git Fix: consumerd: strlen called on uninitialized path closed_trace_chunk_path is uninitialized when relayd_id != 0. Signed-off-by: Jérémie Galarneau Change-Id: I71564bdce0617de7749fc5848764a8cda4d122ea --- diff --git a/src/common/ust-consumer/ust-consumer.c b/src/common/ust-consumer/ust-consumer.c index 81c05d2da..ffbf907da 100644 --- a/src/common/ust-consumer/ust-consumer.c +++ b/src/common/ust-consumer/ust-consumer.c @@ -2177,7 +2177,7 @@ end_rotate_channel_nosignal: const uint64_t relayd_id = msg.u.close_trace_chunk.relayd_id.value; struct lttcomm_consumer_close_trace_chunk_reply reply; - char closed_trace_chunk_path[LTTNG_PATH_MAX]; + char closed_trace_chunk_path[LTTNG_PATH_MAX] = {}; int ret; ret_code = lttng_consumer_close_trace_chunk(