munendrasn commented on a change in pull request #1334: SOLR-8306: Enhance 
ExpandComponent to allow expand.hits=0
URL: https://github.com/apache/lucene-solr/pull/1334#discussion_r392043974
 
 

 ##########
 File path: solr/core/src/java/org/apache/solr/search/DocSlice.java
 ##########
 @@ -56,7 +56,7 @@ public DocSlice(int offset, int len, int[] docs, float[] 
scores, long matches, f
     this.scores=scores;
     this.matches=matches;
     this.maxScore=maxScore;
-    this.ramBytesUsed = BASE_RAM_BYTES_USED + ((long)docs.length << 2) + 
(scores == null ? 0 : 
((long)scores.length<<2)+RamUsageEstimator.NUM_BYTES_ARRAY_HEADER);
+    this.ramBytesUsed = BASE_RAM_BYTES_USED + (docs == null ? 0 : 
((long)docs.length << 2)) + (scores == null ? 0 : 
((long)scores.length<<2)+RamUsageEstimator.NUM_BYTES_ARRAY_HEADER);
 
 Review comment:
   👍 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to