commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sebb (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (LANG-984) DurationFormatUtils does not handle large durations correctly
Date Mon, 03 Mar 2014 21:12:22 GMT

     [ https://issues.apache.org/jira/browse/LANG-984?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Sebb resolved LANG-984.
-----------------------

       Resolution: Fixed
    Fix Version/s:     (was: Patch Needed)

URL: http://svn.apache.org/r1573749
Log:
LANG-984 DurationFormatUtils does not handle large durations correctly

Modified:
    commons/proper/lang/trunk/src/changes/changes.xml
    commons/proper/lang/trunk/src/main/java/org/apache/commons/lang3/time/DurationFormatUtils.java
    commons/proper/lang/trunk/src/test/java/org/apache/commons/lang3/time/DurationFormatUtilsTest.java


> DurationFormatUtils does not handle large durations correctly
> -------------------------------------------------------------
>
>                 Key: LANG-984
>                 URL: https://issues.apache.org/jira/browse/LANG-984
>             Project: Commons Lang
>          Issue Type: Bug
>          Components: lang.time.*
>            Reporter: Sebb
>
> DurationFormatUtils assumes that the the number of days, hours, minutes, seconds and
milliseconds can be expressed as an int when converted from a long duration in milliseconds.
> However even the number of days can exceed an int if the duration is large enough.
> It's unlikely that such large durations will often be used, but this restriction is not
documented. It should be easy enough to use long fields instead of int.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message