Skip to content

Commit 9e452bb

Browse files
yuwatabluca
authored andcommitted
journalctl: fix --no-tail handling
Fixes a bug introduced by 62f21ec. (cherry picked from commit 3f2203f) (cherry picked from commit 75d4967)
1 parent 46ee98e commit 9e452bb

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/journal/journalctl.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1036,7 +1036,10 @@ static int parse_argv(int argc, char *argv[]) {
10361036
assert_not_reached();
10371037
}
10381038

1039-
if (arg_follow && !arg_no_tail && !arg_since_set && arg_lines == ARG_LINES_DEFAULT)
1039+
if (arg_no_tail)
1040+
arg_lines = ARG_LINES_ALL;
1041+
1042+
if (arg_follow && !arg_since_set && arg_lines == ARG_LINES_DEFAULT)
10401043
arg_lines = 10;
10411044

10421045
if (arg_follow && !arg_merge && !arg_boot) {

0 commit comments

Comments
 (0)