Use `return` to avoid running into issues in the future when using
`lttng::scope_exit` objects to perform clean-up.
Change-Id: Id4e4250c7f34355b953702ff8353300acca98ac8
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
ERR("Cannot show --help for `lttng-sessiond`");
perror("exec");
}
- exit(ret ? EXIT_FAILURE : EXIT_SUCCESS);
+ return ret ? EXIT_FAILURE : EXIT_SUCCESS;
} else if (string_match(optname, "version") || opt == 'V') {
opt_print_version = 1;
} else if (string_match(optname, "sig-parent") || opt == 'S') {
exit_set_signal_handler:
if (!retval) {
- exit(EXIT_SUCCESS);
+ return EXIT_SUCCESS;
} else {
- exit(EXIT_FAILURE);
+ return EXIT_FAILURE;
}
}