From 16aa001d9a342adc6b913f854c0cee7a896a7e03 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Galarneau?= Date: Sun, 15 Sep 2019 15:10:20 -0400 Subject: [PATCH] ust-consumer: fix: metadata stream lock taken before destroy MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The lock of a metadata stream is taken when calling the stream's destroy function after the completion of a snapshot. This is invalid and does not appear to protect anything. I am guessin that this was meant to be an 'unlock' invoked in the error path of this functions. Signed-off-by: Jérémie Galarneau --- src/common/ust-consumer/ust-consumer.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/common/ust-consumer/ust-consumer.c b/src/common/ust-consumer/ust-consumer.c index b64ad04aa..f8706d0ba 100644 --- a/src/common/ust-consumer/ust-consumer.c +++ b/src/common/ust-consumer/ust-consumer.c @@ -1079,7 +1079,6 @@ error_stream: * Clean up the stream completly because the next snapshot will use a new * metadata stream. */ - pthread_mutex_lock(&metadata_stream->lock); consumer_stream_destroy(metadata_stream, NULL); cds_list_del(&metadata_stream->send_node); metadata_channel->metadata_stream = NULL; -- 2.34.1