Fix a rounding bug in display of data sizes
authorJoey Hess <joeyh@joeyh.name>
Fri, 30 Jul 2021 13:56:04 +0000 (09:56 -0400)
committerJoey Hess <joeyh@joeyh.name>
Fri, 30 Jul 2021 13:56:04 +0000 (09:56 -0400)
commit66089e97de6d40cf6cf7f464628f42521d0a0bf6
tree8fe36775af50b727f95a853dffa2ad1d115aa7d3
parent1c4d6dee90d6e121249b64e57081e11a3cb084a2
Fix a rounding bug in display of data sizes

Eg, showImprecise 1 1.99 returned "1.1" rather than "2". The 9 rounded
upward to 10, and that was wrongly used as the decimal, rather than
carrying the 1.

Sponsored-by: Jack Hill on Patreon
CHANGELOG
Utility/HumanNumber.hs
doc/bugs/git-annex_info_rounding_error.mdwn
doc/bugs/git-annex_info_rounding_error/comment_1_37079e9f024b048fb0074683f9037d19._comment [new file with mode: 0644]