diff options
Diffstat (limited to 'src/coredump/coredumpctl.c')
-rw-r--r-- | src/coredump/coredumpctl.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/coredump/coredumpctl.c b/src/coredump/coredumpctl.c index 3e9a00bbcf..bffb3d458f 100644 --- a/src/coredump/coredumpctl.c +++ b/src/coredump/coredumpctl.c @@ -414,7 +414,7 @@ static int print_list(FILE* file, sd_journal *j, int had_legend) { else present = "-"; - if (STR_IN_SET(present, "present", "journal") && streq_ptr(truncated, "yes")) + if (STR_IN_SET(present, "present", "journal") && truncated && parse_boolean(truncated) > 0) present = "truncated"; fprintf(file, "%-*s %*s %*s %*s %*s %-*s %s\n", @@ -583,8 +583,10 @@ static int print_info(FILE *file, sd_journal *j, bool need_space) { fprintf(file, " Hostname: %s\n", hostname); if (filename) { - bool inacc = access(filename, R_OK) < 0; - bool trunc = streq_ptr(truncated, "yes"); + bool inacc, trunc; + + inacc = access(filename, R_OK) < 0; + trunc = truncated && parse_boolean(truncated) > 0; if (inacc || trunc) fprintf(file, " Storage: %s%s (%s%s%s)%s\n", |