LUCENE-3397: Fixed HighlighterTest TS reuse

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1161993 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Christopher John Male 2011-08-26 04:59:07 +00:00
parent 0f2d7ad556
commit a0d80d2361
1 changed files with 1 additions and 5 deletions

View File

@ -1821,11 +1821,6 @@ final class SynonymAnalyzer extends Analyzer {
stream.addAttribute(CharTermAttribute.class);
stream.addAttribute(PositionIncrementAttribute.class);
stream.addAttribute(OffsetAttribute.class);
try {
stream.reset();
} catch (IOException e) {
throw new RuntimeException(e);
}
return new SynonymTokenizer(stream, synonyms);
}
}
@ -1901,6 +1896,7 @@ final class SynonymTokenizer extends TokenStream {
@Override
public void reset() throws IOException {
super.reset();
this.realStream.reset();
this.currentRealToken = null;
this.st = null;
}