X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Freadahead%2Freadahead-analyze.c;h=76db3cb7e4b8dc0be437e291d9bf8e3d0c0797cb;hb=010b2b8d7a694e1e404e35db90e938f6a476bf2f;hp=e24b2a32985d041439afc709ffa16e1c3166f828;hpb=268d944e44bea60d5c498cb24a8629f012aac055;p=elogind.git diff --git a/src/readahead/readahead-analyze.c b/src/readahead/readahead-analyze.c index e24b2a329..76db3cb7e 100644 --- a/src/readahead/readahead-analyze.c +++ b/src/readahead/readahead-analyze.c @@ -34,7 +34,7 @@ int main_analyze(const char *pack_path) { char line[LINE_MAX]; - FILE _cleanup_fclose_ *pack = NULL; + _cleanup_fclose_ FILE *pack = NULL; int a; int missing = 0; size_t tsize = 0; @@ -105,7 +105,7 @@ int main_analyze(const char *pack_path) { } if (stat(path, &st) == 0) { - size_t size; + off_t size; if (sections == 0) size = st.st_size; @@ -114,11 +114,11 @@ int main_analyze(const char *pack_path) { tsize += size; - printf(" %4zd%% (%2d) %12zd: %s\n", - sections && st.st_size ? size * 100 / st.st_size : 100, - sections ? sections : 1, - size, - path); + printf(" %4jd%% (%2d) %12jd: %s\n", + (intmax_t) (sections && st.st_size ? size * 100 / st.st_size : 100), + sections ? sections : 1, + (intmax_t) size, + path); } else { printf(" %4dp (%2d) %12s: %s (MISSING)\n", sections ? pages : -1,