]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
sd-journal: warn about seals may not be continuous only when the file is sealed
authorYu Watanabe <watanabe.yu+github@gmail.com>
Tue, 21 Nov 2023 23:44:44 +0000 (08:44 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 22 Nov 2023 01:48:21 +0000 (10:48 +0900)
Follow-up for e375bc5fcc080815ce849261eb505d084c2fde3e.

Fixes #30118.

src/libsystemd/sd-journal/journal-verify.c

index 654993ac81f390f60d9c576189519e5cc62657c3..8fc53beb42eb92f16494829e78c833f22d81aeab 100644 (file)
@@ -925,7 +925,7 @@ int journal_file_verify(
                         goto fail;
                 }
 
-        if (!JOURNAL_HEADER_SEALED_CONTINUOUS(f->header))
+        if (JOURNAL_HEADER_SEALED(f->header) && !JOURNAL_HEADER_SEALED_CONTINUOUS(f->header))
                 warning(p,
                         "This log file was sealed with an old journald version where the sequence of seals might not be continuous. We cannot guarantee completeness.");