You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by afine <gi...@git.apache.org> on 2017/04/07 02:43:19 UTC

[GitHub] zookeeper issue #220: ZOOKEEPER-2729: Cleanup findbug warnings in branch-3.4...

Github user afine commented on the issue:

    https://github.com/apache/zookeeper/pull/220
  
    @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.
---