]> err.no Git - systemd/commitdiff
systemd-journald: fix endianess bug
authorDirk Eibach <eibach@gdsys.de>
Wed, 29 Feb 2012 11:45:46 +0000 (12:45 +0100)
committerLennart Poettering <lennart@poettering.net>
Wed, 29 Feb 2012 13:06:33 +0000 (14:06 +0100)
src/journal/journal-file.c

index 20ca3f61cbd446bf10f8b6fbb318cc9b25160937..275caea50e10a7625007f0164ef3be4e6cbad192 100644 (file)
@@ -238,7 +238,7 @@ static int journal_file_allocate(JournalFile *f, uint64_t offset, uint64_t size)
         if (fstat(f->fd, &f->last_stat) < 0)
                 return -errno;
 
-        f->header->arena_size = new_size - htole64(f->header->arena_offset);
+        f->header->arena_size = htole64(new_size - le64toh(f->header->arena_offset));
 
         return 0;
 }