]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
journal: explain the error when we find a non-DATA object that is compressed
authorLennart Poettering <lennart@poettering.net>
Fri, 24 Jul 2015 00:02:07 +0000 (02:02 +0200)
committerLennart Poettering <lennart@poettering.net>
Fri, 24 Jul 2015 00:02:07 +0000 (02:02 +0200)
Only objects of type DATA may be compressed, generate a message about
that, like we do for all other errros.

src/journal/journal-verify.c

index 637162e30535ae02f361d4be11bd0f70a9689090..0a8f30ceca482dda41bc55dc24fb22af1611a8d6 100644 (file)
@@ -123,8 +123,10 @@ static int journal_file_object_verify(JournalFile *f, uint64_t offset, Object *o
          * other objects. */
 
         if ((o->object.flags & OBJECT_COMPRESSED_XZ) &&
-            o->object.type != OBJECT_DATA)
+            o->object.type != OBJECT_DATA) {
+                error(offset, "Found compressed object that isn't of type DATA, which is not allowed.");
                 return -EBADMSG;
+        }
 
         switch (o->object.type) {