lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yonik Seeley (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (SOLR-9873) Function result is compared with itself
Date Fri, 16 Dec 2016 23:42:58 GMT

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

Yonik Seeley resolved SOLR-9873.
--------------------------------
       Resolution: Fixed
    Fix Version/s: 6.4
                   master (7.0)

> Function result is compared with itself
> ---------------------------------------
>
>                 Key: SOLR-9873
>                 URL: https://issues.apache.org/jira/browse/SOLR-9873
>             Project: Solr
>          Issue Type: Bug
>      Security Level: Public(Default Security Level. Issues are Public) 
>    Affects Versions: 6.3
>            Reporter: AppChecker
>            Assignee: Yonik Seeley
>            Priority: Minor
>             Fix For: master (7.0), 6.4
>
>
> Hi!
> In the method [SolrTestCaseJ4.compareSolrDocument|https://github.com/apache/lucene-solr/blob/c9522a393661c8878d488ad4475ac7e2cbb9c25c/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.java#L1951]
> {code:title=SolrTestCaseJ4.java|borderStyle=solid}
>     if(solrDocument1.getFieldNames().size() != solrDocument1.getFieldNames().size())
{
>       return false;
>     }
> {code}
> "solrDocument1.getFieldNames().size()" compare with itself
> Probably, is should be:
> {code:title=SolrTestCaseJ4.java|borderStyle=solid}
>     if(solrDocument1.getFieldNames().size() != solrDocument2.getFieldNames().size())
{
>       return false;
>     }
> {code}
> This possible defect found by [static code analyzer AppChecker|http://cnpo.ru/en/solutions/appchecker.php]



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Mime
View raw message