[Bug 9041] New: ls -lh does true rounding

bugzilla at busybox.net bugzilla at busybox.net
Wed Jun 22 22:45:40 UTC 2016


https://bugs.busybox.net/show_bug.cgi?id=9041

            Bug ID: 9041
           Summary: ls -lh does true rounding
           Product: Busybox
           Version: 1.23.x
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P5
         Component: Other
          Assignee: unassigned at busybox.net
          Reporter: john.ata at baesystems.com
                CC: busybox-cvs at busybox.net
  Target Milestone: ---

Given a file with 5734510790 bytes, Linux reports it with the -h option as 5.4G
while busybox reports it as 5.3G.   This is because Linux always rounds up no
matter how small the fraction while busybox does true rounding (The fraction is
5.340679353103042).  Normally a nit, however, when comparing identical
directories on two systems, this could get confusing leading one to believe
that identical files are in fact different.  I realize that there's good
arguments for both approaches but wondered if someone had thought about it.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the busybox-cvs mailing list