From 38970582d525b5afa11249ce5b7ee8c66cf933d5 Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Sat, 19 Nov 2011 09:39:42 -0500 Subject: [PATCH] ustctl: do not free object on release_object Signed-off-by: Mathieu Desnoyers --- liblttng-ust-ctl/ustctl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/liblttng-ust-ctl/ustctl.c b/liblttng-ust-ctl/ustctl.c index e285a2d2..7cd01771 100644 --- a/liblttng-ust-ctl/ustctl.c +++ b/liblttng-ust-ctl/ustctl.c @@ -61,7 +61,6 @@ void ustctl_release_object(int sock, struct lttng_ust_object_data *data) ret = ustcomm_send_app_cmd(sock, &lum, &lur); assert(!ret); } - free(data); } /* @@ -162,6 +161,7 @@ int ustctl_open_metadata(int sock, int session_handle, error: ustctl_release_object(sock, metadata_data); + free(metadata_data); return -EINVAL; } @@ -215,6 +215,7 @@ int ustctl_create_channel(int sock, int session_handle, error: ustctl_release_object(sock, channel_data); + free(channel_data); return -EINVAL; } @@ -266,6 +267,7 @@ int ustctl_create_stream(int sock, struct lttng_ust_object_data *channel_data, error: ustctl_release_object(sock, stream_data); + free(stream_data); return -EINVAL; } -- 2.34.1