mirror of https://github.com/apache/lucene.git
LUCENE-1554: remove false-positive assert that may (rarely) trip when it's not supposed to
git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@750849 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
ebb8c8ec3d
commit
11079efed4
|
@ -4427,14 +4427,16 @@ public class IndexWriter {
|
||||||
if (merge.increfDone)
|
if (merge.increfDone)
|
||||||
decrefMergeSegments(merge);
|
decrefMergeSegments(merge);
|
||||||
|
|
||||||
assert merge.registerDone;
|
// It's possible we are called twice, eg if there was an
|
||||||
|
// exception inside mergeInit
|
||||||
final SegmentInfos sourceSegments = merge.segments;
|
if (merge.registerDone) {
|
||||||
final int end = sourceSegments.size();
|
final SegmentInfos sourceSegments = merge.segments;
|
||||||
for(int i=0;i<end;i++)
|
final int end = sourceSegments.size();
|
||||||
mergingSegments.remove(sourceSegments.info(i));
|
for(int i=0;i<end;i++)
|
||||||
mergingSegments.remove(merge.info);
|
mergingSegments.remove(sourceSegments.info(i));
|
||||||
merge.registerDone = false;
|
mergingSegments.remove(merge.info);
|
||||||
|
merge.registerDone = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Does the actual (time-consuming) work of the merge,
|
/** Does the actual (time-consuming) work of the merge,
|
||||||
|
|
Loading…
Reference in New Issue