From: David Goulet Date: Tue, 21 Aug 2012 16:31:14 +0000 (-0400) Subject: Fix: missing mutex unlock on register consumer err X-Git-Tag: v2.1.0-rc2~4 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=fa317f24049f7f1ee769969675c2b61e0c770fbf;p=lttng-tools.git Fix: missing mutex unlock on register consumer err Reported-by: Julien Desfossez Signed-off-by: David Goulet --- diff --git a/src/bin/lttng-sessiond/main.c b/src/bin/lttng-sessiond/main.c index b9c2177fa..76d185700 100644 --- a/src/bin/lttng-sessiond/main.c +++ b/src/bin/lttng-sessiond/main.c @@ -2033,6 +2033,7 @@ static int process_client_msg(struct command_ctx *cmd_ctx, int sock, pthread_mutex_lock(&kconsumer_data.pid_mutex); if (kconsumer_data.pid > 0) { ret = LTTCOMM_KERN_CONSUMER_FAIL; + pthread_mutex_unlock(&kconsumer_data.pid_mutex); goto error; } pthread_mutex_unlock(&kconsumer_data.pid_mutex);