chiark / gitweb /
journal: be more careful when keeping around mmaps we still need
[elogind.git] / src / journal / journal-verify.c
index 90739a66c2cde0c2283540764b78fe3a3915c090..9156fd5dc0a3e7d0c94a13edf468bcf2353fb5a4 100644 (file)
@@ -249,7 +249,7 @@ static int contains_uint64(MMapCache *m, int fd, uint64_t n, uint64_t p) {
 
                 c = (a + b) / 2;
 
-                r = mmap_cache_get(m, fd, PROT_READ|PROT_WRITE, 0, c * sizeof(uint64_t), sizeof(uint64_t), (void **) &z);
+                r = mmap_cache_get(m, fd, PROT_READ|PROT_WRITE, 0, false, c * sizeof(uint64_t), sizeof(uint64_t), NULL, (void **) &z);
                 if (r < 0)
                         return r;
 
@@ -261,9 +261,8 @@ static int contains_uint64(MMapCache *m, int fd, uint64_t n, uint64_t p) {
 
                 if (p < *z)
                         b = c;
-                else {
+                else
                         a = c;
-                }
         }
 
         return 0;