summaryrefslogtreecommitdiff
path: root/src/journal/journalctl.c
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2018-03-14 17:48:29 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2018-03-19 21:04:02 +0900
commitee5324aa04bb46a9a8e1ad23307efa85e05879b6 (patch)
tree85cd5851f9d9139c25291f08f04307b1340e58a3 /src/journal/journalctl.c
parent24fcd009c3eb89f590bef96dd5495fd4ef796fd0 (diff)
downloadsystemd-ee5324aa04bb46a9a8e1ad23307efa85e05879b6.tar.gz
tree-wide: voidify pager_open()
Even if pager_open() fails, in general, we should continue the operations. All erroneous cases in pager_open() show log message in the function. So, it is not necessary to check the returned value.
Diffstat (limited to 'src/journal/journalctl.c')
-rw-r--r--src/journal/journalctl.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c
index e0ad0e1d11..3c9c6df07d 100644
--- a/src/journal/journalctl.c
+++ b/src/journal/journalctl.c
@@ -316,7 +316,7 @@ static int parse_boot_descriptor(const char *x, sd_id128_t *boot_id, int *offset
static void help(void) {
- pager_open(arg_no_pager, arg_pager_end);
+ (void) pager_open(arg_no_pager, arg_pager_end);
printf("%s [OPTIONS...] [MATCHES...]\n\n"
"Query the journal.\n\n"
@@ -1369,7 +1369,7 @@ static int list_boots(sd_journal *j) {
if (count == 0)
return count;
- pager_open(arg_no_pager, arg_pager_end);
+ (void) pager_open(arg_no_pager, arg_pager_end);
/* numbers are one less, but we need an extra char for the sign */
w = DECIMAL_STR_WIDTH(count - 1) + 1;
@@ -2135,7 +2135,7 @@ int main(int argc, char *argv[]) {
} else {
bool oneline = arg_action == ACTION_LIST_CATALOG;
- pager_open(arg_no_pager, arg_pager_end);
+ (void) pager_open(arg_no_pager, arg_pager_end);
if (optind < argc)
r = catalog_list_items(stdout, database, oneline, argv + optind);
@@ -2492,7 +2492,7 @@ int main(int argc, char *argv[]) {
need_seek = true;
if (!arg_follow)
- pager_open(arg_no_pager, arg_pager_end);
+ (void) pager_open(arg_no_pager, arg_pager_end);
if (!arg_quiet && (arg_lines != 0 || arg_follow)) {
usec_t start, end;