mirror of https://github.com/apache/lucene.git
SOLR-7371: Fix NPE when scores are null
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1672402 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
32c78bc382
commit
c400bde439
|
@ -59,7 +59,7 @@ public class DocSlice extends DocSetBase implements DocList {
|
|||
this.scores=scores;
|
||||
this.matches=matches;
|
||||
this.maxScore=maxScore;
|
||||
this.ramBytesUsed = BASE_RAM_BYTES_USED + RamUsageEstimator.sizeOf(docs) + RamUsageEstimator.sizeOf(scores);
|
||||
this.ramBytesUsed = BASE_RAM_BYTES_USED + RamUsageEstimator.sizeOf(docs) + (scores != null ? RamUsageEstimator.sizeOf(scores) : 0);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in New Issue