projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
cppcheck: Simplify empty string test without using strlen()
[lttng-tools.git]
/
src
/
bin
/
lttng-sessiond
/
cmd.c
diff --git
a/src/bin/lttng-sessiond/cmd.c
b/src/bin/lttng-sessiond/cmd.c
index 456ddeb77d85fd4d1a6f70ca7116494435a12b5e..bdc9c9acab52a1cbe893efe1faaa50198b27206e 100644
(file)
--- a/
src/bin/lttng-sessiond/cmd.c
+++ b/
src/bin/lttng-sessiond/cmd.c
@@
-105,7
+105,7
@@
static int build_network_session_path(char *dst, size_t size,
* Do we have a UST url set. If yes, this means we have both kernel and UST
* to print.
*/
* Do we have a UST url set. If yes, this means we have both kernel and UST
* to print.
*/
- if (
strlen(tmp_uurl) > 0
) {
+ if (
*tmp_uurl != '\0'
) {
ret = snprintf(dst, size, "[K]: %s [data: %d] -- [U]: %s [data: %d]",
tmp_urls, kdata_port, tmp_uurl, udata_port);
} else {
ret = snprintf(dst, size, "[K]: %s [data: %d] -- [U]: %s [data: %d]",
tmp_urls, kdata_port, tmp_uurl, udata_port);
} else {
This page took
0.024343 seconds
and
4
git commands to generate.