projects
/
lttng-tools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
00e4a0a
)
Fix: handle invalid URL passed to lttng_create_session_live
author
David Goulet
<dgoulet@efficios.com>
Tue, 4 Feb 2014 19:52:49 +0000
(14:52 -0500)
committer
David Goulet
<dgoulet@efficios.com>
Tue, 4 Feb 2014 19:52:49 +0000
(14:52 -0500)
uri_parse_str_urls() returns 0 if the URL passed is NULL thus using
lttng_create_session_live() without an URL is invalid.
Reported-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
src/lib/lttng-ctl/lttng-ctl.c
patch
|
blob
|
blame
|
history
diff --git
a/src/lib/lttng-ctl/lttng-ctl.c
b/src/lib/lttng-ctl/lttng-ctl.c
index 3f6635e8f759c751d11f3d5402452ca9f7d37aeb..7d06c7a0cb41b8f3396e4460c92c25afbc501d8b 100644
(file)
--- a/
src/lib/lttng-ctl/lttng-ctl.c
+++ b/
src/lib/lttng-ctl/lttng-ctl.c
@@
-1558,7
+1558,7
@@
int lttng_create_session_live(const char *name, const char *url,
lttng_ctl_copy_string(lsm.session.name, name, sizeof(lsm.session.name));
size = uri_parse_str_urls(url, NULL, &uris);
- if (size < 0) {
+ if (size <
=
0) {
ret = -LTTNG_ERR_INVALID;
goto end;
}
This page took
0.026664 seconds
and
4
git commands to generate.