diff options
author | Lennart Poettering <lennart@poettering.net> | 2012-07-03 21:22:08 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2012-07-03 21:22:08 +0200 |
commit | 047e111bdddfed52dabc7ff8242c2eec78e126fb (patch) | |
tree | c488efc81340ec39f1338e892948658503a3c5eb /src/readahead | |
parent | 2d938ac75d013f713c1225def78a53583af6a596 (diff) |
readahead: fix calculation of percentage
Diffstat (limited to 'src/readahead')
-rw-r--r-- | src/readahead/readahead-analyze.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/readahead/readahead-analyze.c b/src/readahead/readahead-analyze.c index 8f1d7f9c4f..53892b0cf8 100644 --- a/src/readahead/readahead-analyze.c +++ b/src/readahead/readahead-analyze.c @@ -115,7 +115,7 @@ int main_analyze(const char *pack_path) { tsize += size; printf(" %4d%% (%2d) %12ld: %s\n", - sections ? (int)(size / st.st_size * 100.0) : 100, + sections ? (int) (size * 100 / st.st_size) : 100, sections ? sections : 1, (unsigned long)size, path); |