mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
virsh: Always print capacity unit
It doesn't make sense to print the unit (B) only with Ki, Mi, ... prefixes. Even those poor bytes under 1 KiB are still bytes :-)
This commit is contained in:
parent
e086deda3c
commit
ada9e157a2
@ -148,7 +148,7 @@ double
|
||||
vshPrettyCapacity(unsigned long long val, const char **unit)
|
||||
{
|
||||
if (val < 1024) {
|
||||
*unit = "";
|
||||
*unit = "B";
|
||||
return (double)val;
|
||||
} else if (val < (1024.0l * 1024.0l)) {
|
||||
*unit = "KiB";
|
||||
|
Loading…
Reference in New Issue
Block a user