[
https://issues.apache.org/jira/browse/OFBIZ-9627?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michael Brohl closed OFBIZ-9627.
--------------------------------
Resolution: Implemented
Fix Version/s: Upcoming Release
Thanks Dennis,
your patch is in trunk r1811421.
> [FB] Package org.apache.ofbiz.common.authentication
> ---------------------------------------------------
>
> Key: OFBIZ-9627
> URL:
https://issues.apache.org/jira/browse/OFBIZ-9627> Project: OFBiz
> Issue Type: Sub-task
> Components: framework
> Affects Versions: Trunk
> Reporter: Dennis Balkir
> Assignee: Michael Brohl
> Priority: Minor
> Fix For: Upcoming Release
>
> Attachments: OFBIZ-9627_org.apache.ofbiz.common.authentification_bugfixes.patch
>
>
> - AuthenticationComparator.java:31, SE_COMPARATOR_SHOULD_BE_SERIALIZABLE
> Se: org.apache.ofbiz.common.authentication.AuthenticationComparator implements Comparator but not Serializable
> This class implements the Comparator interface. You should consider whether or not it should also implement the Serializable interface. If a comparator is used to construct an ordered collection such as a TreeMap, then the TreeMap will be serializable only if the comparator is also serializable. As most comparators have little or no state, making them serializable is generally easy and good defensive programming.
> - AuthenticationComparator.java:70, CO_COMPARETO_INCORRECT_FLOATING
> compareTo()/compare() incorrectly handles float or double value
> This method compares double or float values using pattern like this: val1 > val2 ? 1 : val1 < val2 ? -1 : 0. This pattern works incorrectly for -0.0 and NaN values which may result in incorrect sorting result or broken collection (if compared values are used as keys). Consider using Double.compare or Float.compare static methods which handle all the special cases correctly.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)