projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: Memory leak in relay_add_stream error path
[lttng-tools.git]
/
src
/
bin
/
lttng-relayd
/
main.c
diff --git
a/src/bin/lttng-relayd/main.c
b/src/bin/lttng-relayd/main.c
index 178e002347f095698b529977813e6998a86eaddf..8ab60d4cd05f446013a5d8d787007303fa41cf08 100644
(file)
--- a/
src/bin/lttng-relayd/main.c
+++ b/
src/bin/lttng-relayd/main.c
@@
-1285,7
+1285,7
@@
end:
if (ret < 0) {
reply.ret_code = htobe32(LTTNG_ERR_UNK);
/* stream was not properly added to the ht, so free it */
if (ret < 0) {
reply.ret_code = htobe32(LTTNG_ERR_UNK);
/* stream was not properly added to the ht, so free it */
-
free
(stream);
+
stream_destroy
(stream);
} else {
reply.ret_code = htobe32(LTTNG_OK);
}
} else {
reply.ret_code = htobe32(LTTNG_OK);
}
@@
-1302,9
+1302,7
@@
end_no_session:
return ret;
err_free_stream:
return ret;
err_free_stream:
- free(stream->path_name);
- free(stream->channel_name);
- free(stream);
+ stream_destroy(stream);
return ret;
}
return ret;
}
This page took
0.023642 seconds
and
4
git commands to generate.