X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fjournal%2Fjournal-vacuum.c;h=7699482a7756c13f69769bae2aea664159781c82;hb=cc821d02a37c8c76aaf15bae2d33fee1bdc4b2e0;hp=086b40f9438b092f7c9892ee7853c2631c04200f;hpb=d2edfae0f9bdbecf6a8518e2a5bcf06f470e0d9e;p=elogind.git diff --git a/src/journal/journal-vacuum.c b/src/journal/journal-vacuum.c index 086b40f94..7699482a7 100644 --- a/src/journal/journal-vacuum.c +++ b/src/journal/journal-vacuum.c @@ -89,15 +89,15 @@ static void patch_realtime( assert(realtime); x = timespec_load(&st->st_ctim); - if (x > 0 && x != (usec_t) -1 && x < *realtime) + if (x > 0 && x != USEC_INFINITY && x < *realtime) *realtime = x; x = timespec_load(&st->st_atim); - if (x > 0 && x != (usec_t) -1 && x < *realtime) + if (x > 0 && x != USEC_INFINITY && x < *realtime) *realtime = x; x = timespec_load(&st->st_mtim); - if (x > 0 && x != (usec_t) -1 && x < *realtime) + if (x > 0 && x != USEC_INFINITY && x < *realtime) *realtime = x; /* Let's read the original creation time, if possible. Ideally @@ -292,13 +292,6 @@ int journal_directory_vacuum( qsort_safe(list, n_list, sizeof(struct vacuum_info), vacuum_compare); for (i = 0; i < n_list; i++) { - struct statvfs ss; - - if (fstatvfs(dirfd(d), &ss) < 0) { - r = -errno; - goto finish; - } - if ((max_retention_usec <= 0 || list[i].realtime >= retention_limit) && (max_use <= 0 || sum <= max_use)) break;