1
0
mirror of https://github.com/xzeldon/htop.git synced 2025-04-08 12:07:08 +03:00

kilobytes is the smallest unit and never has precision

Signed-off-by: Christian Hesse <mail@eworm.de>
This commit is contained in:
Christian Hesse 2015-08-28 10:40:33 +02:00
parent a859e9204c
commit bf456972b7

@ -157,6 +157,9 @@ int Meter_humanUnit(char* buffer, unsigned long int value, int size) {
++prefix;
}
if (*prefix == 'K')
precision = 0;
for (; precision > 0; precision--) {
powj *= 10;
if (value / powi < powj)