Re-apply pull-request #3956 now that the CLA has been signed.

This commit is contained in:
Adrien Grand 2013-10-25 19:05:20 +02:00
parent f9154de04f
commit b0b3748cae
1 changed files with 2 additions and 0 deletions

View File

@ -276,6 +276,7 @@ public class ChildrenQuery extends Query {
@Override @Override
public int nextDoc() throws IOException { public int nextDoc() throws IOException {
if (remaining == 0) { if (remaining == 0) {
currentDocId = NO_MORE_DOCS;
return NO_MORE_DOCS; return NO_MORE_DOCS;
} }
@ -297,6 +298,7 @@ public class ChildrenQuery extends Query {
@Override @Override
public int advance(int target) throws IOException { public int advance(int target) throws IOException {
if (remaining == 0) { if (remaining == 0) {
currentDocId = NO_MORE_DOCS;
return NO_MORE_DOCS; return NO_MORE_DOCS;
} }