projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Teardown the notification thread after the sessiond clean-up
[lttng-tools.git]
/
src
/
bin
/
lttng-crash
/
lttng-crash.c
diff --git
a/src/bin/lttng-crash/lttng-crash.c
b/src/bin/lttng-crash/lttng-crash.c
index 65fca36ae264c2e25f7d0437840a4a8f194f67b7..298ed71a43c2b1b47053156f624aa50b39fd0519 100644
(file)
--- a/
src/bin/lttng-crash/lttng-crash.c
+++ b/
src/bin/lttng-crash/lttng-crash.c
@@
-61,6
+61,14
@@
0xF1 ^ 0xFF, 0x77 ^ 0xFF, 0xBF ^ 0xFF, 0x17 ^ 0xFF, \
}
0xF1 ^ 0xFF, 0x77 ^ 0xFF, 0xBF ^ 0xFF, 0x17 ^ 0xFF, \
}
+static const char *help_msg =
+#ifdef LTTNG_EMBED_HELP
+#include <lttng-crash.1.h>
+#else
+NULL
+#endif
+;
+
/*
* Non-static to ensure the compiler does not optimize away the xor.
*/
/*
* Non-static to ensure the compiler does not optimize away the xor.
*/
@@
-207,10
+215,10
@@
static struct option long_options[] = {
static void usage(void)
{
static void usage(void)
{
- int ret = utils_show_
man_page(1, "lttng-crash"
);
+ int ret = utils_show_
help(1, "lttng-crash", help_msg
);
if (ret) {
if (ret) {
- ERR("Cannot
view man page lttng-crash(1)
");
+ ERR("Cannot
show --help for `lttng-crash`
");
perror("exec");
exit(EXIT_FAILURE);
}
perror("exec");
exit(EXIT_FAILURE);
}
@@
-1079,7
+1087,7
@@
int delete_dir_recursive(const char *path)
if (!dir) {
PERROR("Cannot open '%s' path", path);
ret = -errno;
if (!dir) {
PERROR("Cannot open '%s' path", path);
ret = -errno;
- goto end;
+ goto end
_no_closedir
;
}
path_len = strlen(path);
}
path_len = strlen(path);
@@
-1137,7
+1145,7
@@
int delete_dir_recursive(const char *path)
ret = delete_dir_recursive(subpath);
free(subpath);
if (ret) {
ret = delete_dir_recursive(subpath);
free(subpath);
if (ret) {
- /* Error occured, abort traversal. */
+ /* Error occur
r
ed, abort traversal. */
goto end;
}
} else if (S_ISREG(st.st_mode)) {
goto end;
}
} else if (S_ISREG(st.st_mode)) {
@@
-1162,6
+1170,7
@@
end:
if (closeret) {
PERROR("closedir");
}
if (closeret) {
PERROR("closedir");
}
+end_no_closedir:
return ret;
}
return ret;
}
This page took
0.041324 seconds
and
4
git commands to generate.