lucene-solr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shalin Shekhar Mangar <shalinman...@gmail.com>
Subject Re: svn commit: r763791 - /lucene/solr/trunk/src/solrj/org/apache/solr/client/solrj/response/QueryResponse.java
Date Fri, 10 Apr 2009 07:29:11 GMT
I think this is the same as SOLR-1021? If yes, we can mark that issue as
resolved.

On Fri, Apr 10, 2009 at 1:54 AM, <ryan@apache.org> wrote:

> Author: ryan
> Date: Thu Apr  9 20:24:34 2009
> New Revision: 763791
>
> URL: http://svn.apache.org/viewvc?rev=763791&view=rev
> Log:
> fix potential NPE with FieldStatsInfo
>
> Modified:
>
>  lucene/solr/trunk/src/solrj/org/apache/solr/client/solrj/response/QueryResponse.java
>
> Modified:
> lucene/solr/trunk/src/solrj/org/apache/solr/client/solrj/response/QueryResponse.java
> URL:
> http://svn.apache.org/viewvc/lucene/solr/trunk/src/solrj/org/apache/solr/client/solrj/response/QueryResponse.java?rev=763791&r1=763790&r2=763791&view=diff
>
> ==============================================================================
> ---
> lucene/solr/trunk/src/solrj/org/apache/solr/client/solrj/response/QueryResponse.java
> (original)
> +++
> lucene/solr/trunk/src/solrj/org/apache/solr/client/solrj/response/QueryResponse.java
> Thu Apr  9 20:24:34 2009
> @@ -131,8 +131,11 @@
>       NamedList<NamedList<Object>> ff = (NamedList<NamedList<Object>>)
> info.get( "stats_fields" );
>       if( ff != null ) {
>         for( Map.Entry<String,NamedList<Object>> entry : ff ) {
> -          _fieldStatsInfo.put( entry.getKey(),
> -              new FieldStatsInfo( entry.getValue(), entry.getKey() ) );
> +          NamedList<Object> v = entry.getValue();
> +          if( v != null ) {
> +            _fieldStatsInfo.put( entry.getKey(),
> +                new FieldStatsInfo( v, entry.getKey() ) );
> +          }
>         }
>       }
>     }
>
>
>


-- 
Regards,
Shalin Shekhar Mangar.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message