mirror of https://github.com/apache/lucene.git
LUCENE-4908: Fix SortingDocsAndPositionsEnum.docID() when the enum is not positioned yet.
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1464768 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
b6a89d97cb
commit
88ae7ffa13
|
@ -559,7 +559,7 @@ public class SortingAtomicReader extends FilterAtomicReader {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int docID() {
|
public int docID() {
|
||||||
return docIt >= upto ? NO_MORE_DOCS : docs[docIt];
|
return docIt < 0 ? -1 : docIt >= upto ? NO_MORE_DOCS : docs[docIt];
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in New Issue