mirror of https://github.com/apache/lucene.git
Revert to resolve conflicts.
This commit is contained in:
parent
fff6116dd2
commit
07ab2eb6e8
|
@ -59,12 +59,6 @@ final class FreqProxTermsWriter extends TermsHash {
|
|||
FrozenBufferedUpdates.TermDocsIterator iterator =
|
||||
new FrozenBufferedUpdates.TermDocsIterator(fields, true);
|
||||
|
||||
// Since we have already applied delete-by-docID, liveDocs maybe not null.
|
||||
if (state.liveDocs == null) {
|
||||
state.liveDocs = new FixedBitSet(state.segmentInfo.maxDoc());
|
||||
state.liveDocs.set(0, state.segmentInfo.maxDoc());
|
||||
}
|
||||
|
||||
segDeletes.forEachOrdered(
|
||||
(term, docId) -> {
|
||||
DocIdSetIterator postings = iterator.nextTerm(term.field(), term.bytes());
|
||||
|
@ -72,17 +66,16 @@ final class FreqProxTermsWriter extends TermsHash {
|
|||
assert docId < PostingsEnum.NO_MORE_DOCS;
|
||||
int doc;
|
||||
while ((doc = postings.nextDoc()) < docId) {
|
||||
if (state.liveDocs.get(doc)) {
|
||||
if (state.liveDocs == null) {
|
||||
state.liveDocs = new FixedBitSet(state.segmentInfo.maxDoc());
|
||||
state.liveDocs.set(0, state.segmentInfo.maxDoc());
|
||||
}
|
||||
if (state.liveDocs.getAndClear(doc)) {
|
||||
state.delCountOnFlush++;
|
||||
state.liveDocs.clear(doc);
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
if (state.delCountOnFlush == 0) {
|
||||
state.liveDocs = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue