mirror of https://github.com/apache/lucene.git
also set tvd/tvf to null after close
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/branches/realtime_search@1097521 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
726654c1ab
commit
1a1060611c
|
@ -57,9 +57,10 @@ final class TermVectorsTermsWriter extends TermsHashConsumer {
|
||||||
tvx.close();
|
tvx.close();
|
||||||
tvf.close();
|
tvf.close();
|
||||||
tvd.close();
|
tvd.close();
|
||||||
tvx = null;
|
tvx = tvd = tvf = null;
|
||||||
if (4+((long) state.numDocs)*16 != state.directory.fileLength(idxName))
|
if (4+((long) state.numDocs)*16 != state.directory.fileLength(idxName)) {
|
||||||
throw new RuntimeException("after flush: tvx size mismatch: " + state.numDocs + " docs vs " + state.directory.fileLength(idxName) + " length in bytes of " + idxName + " file exists?=" + state.directory.fileExists(idxName));
|
throw new RuntimeException("after flush: tvx size mismatch: " + state.numDocs + " docs vs " + state.directory.fileLength(idxName) + " length in bytes of " + idxName + " file exists?=" + state.directory.fileExists(idxName));
|
||||||
|
}
|
||||||
|
|
||||||
lastDocID = 0;
|
lastDocID = 0;
|
||||||
state.hasVectors = hasVectors;
|
state.hasVectors = hasVectors;
|
||||||
|
|
Loading…
Reference in New Issue