summaryrefslogtreecommitdiff
path: root/src/journal/journalctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/journal/journalctl.c')
-rw-r--r--src/journal/journalctl.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c
index 3d274c8eb5..25e441b022 100644
--- a/src/journal/journalctl.c
+++ b/src/journal/journalctl.c
@@ -601,13 +601,18 @@ static int verify(sd_journal *j) {
HASHMAP_FOREACH(f, j->files, i) {
int k;
+#ifdef HAVE_GCRYPT
if (!arg_verify_seed && journal_file_fsprg_enabled(f))
log_warning("Journal file %s has authentication enabled but verification seed has not been passed using --verify-seed=.", f->path);
+#endif
k = journal_file_verify(f, arg_verify_seed);
- if (k < 0) {
+ if (k == -EINVAL) {
+ /* If the seed was invalid give up right-away. */
+ return k;
+ } else if (k < 0) {
log_warning("FAIL: %s (%s)", f->path, strerror(-k));
- r = -r;
+ r = k;
} else
log_info("PASS: %s", f->path);
}