commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jonathan (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (IO-226) Rounding issue with byteCountToDisplaySize(long size)
Date Thu, 27 Sep 2018 12:29:06 GMT

    [ https://issues.apache.org/jira/browse/IO-226?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16630304#comment-16630304
] 

Jonathan edited comment on IO-226 at 9/27/18 12:28 PM:
-------------------------------------------------------

Hi,

Any update about this merge or fix to have 2 digits precision?


was (Author: fortin):
Hi,

Any update about this merge or fix to have 2 digit precision?

> Rounding issue with byteCountToDisplaySize(long size)
> -----------------------------------------------------
>
>                 Key: IO-226
>                 URL: https://issues.apache.org/jira/browse/IO-226
>             Project: Commons IO
>          Issue Type: Improvement
>          Components: Utilities
>            Reporter: shu kai yuan
>            Priority: Major
>             Fix For: 2.0
>
>         Attachments: roundedByteCountToDisplaySize.patch
>
>
> I do not understand the byteCountToDisplaySize(long size) method which is in  class FileUtils
of the package org.apache.commons.io.
> If  the parameter size is 2047 , the method will return 1 KB.Why it will lose precision.
> I read the code. 
> Maybe it is a bug?



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message