mirror of https://github.com/apache/lucene.git
SOLR-2092: fix off-by-one in assert
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@992410 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
ccc91689b2
commit
495e614234
|
@ -508,7 +508,7 @@ public class SimpleFacets {
|
|||
|
||||
// if we are deep paging, we don't have to order the highest "offset" counts.
|
||||
int collectCount = Math.max(0, queue.size() - off);
|
||||
assert collectCount < lim;
|
||||
assert collectCount <= lim;
|
||||
|
||||
// the start and end indexes of our list "sorted" (starting with the highest value)
|
||||
int sortedIdxStart = queue.size() - (collectCount - 1);
|
||||
|
|
|
@ -599,7 +599,7 @@ public class UnInvertedField {
|
|||
|
||||
// if we are deep paging, we don't have to order the highest "offset" counts.
|
||||
int collectCount = Math.max(0, queue.size() - off);
|
||||
assert collectCount < lim;
|
||||
assert collectCount <= lim;
|
||||
|
||||
// the start and end indexes of our list "sorted" (starting with the highest value)
|
||||
int sortedIdxStart = queue.size() - (collectCount - 1);
|
||||
|
|
Loading…
Reference in New Issue