zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From afine <...@git.apache.org>
Subject [GitHub] zookeeper issue #220: ZOOKEEPER-2729: Cleanup findbug warnings in branch-3.4...
Date Fri, 07 Apr 2017 02:43:19 GMT
Github user afine commented on the issue:

    @rakeshadr @hanm 
    Both of the findbugs related issues here appear to be from from ZOOKEEPER-1045. There
were checks for an array length of less than zero `if (response != null && response.length
< 0) {`. 
    According to the java spec (http://docs.oracle.com/javase/specs/jls/se7/html/jls-10.html#jls-10.7)
this is an impossible condition. 
    >The public final field length, which contains the number of components of the array.
length may be positive or zero.
    So I just remove the clause from the if block, please let me know if I am missing something.

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.

View raw message