From b12c38dfb3ff3b7333ac79cf06e009199d203957 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Galarneau?= Date: Fri, 26 Feb 2016 15:14:04 -0500 Subject: [PATCH] Fix: return negative error code in list_lttng_ust_global_events() MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérémie Galarneau --- src/bin/lttng-sessiond/cmd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bin/lttng-sessiond/cmd.c b/src/bin/lttng-sessiond/cmd.c index 800859b8e..dee7bedf1 100644 --- a/src/bin/lttng-sessiond/cmd.c +++ b/src/bin/lttng-sessiond/cmd.c @@ -360,8 +360,8 @@ static int list_lttng_ust_global_events(char *channel_name, *total_size = nb_event * sizeof(struct lttng_event) + extended_len; tmp = zmalloc(*total_size); if (tmp == NULL) { - ret = LTTNG_ERR_FATAL; - goto error; + ret = -LTTNG_ERR_FATAL; + goto end; } extended_at = ((uint8_t *) tmp) + nb_event * sizeof(struct lttng_event); -- 2.34.1