LUCENE-2374: Fix bug in position-sorting - too stupid :(

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1061078 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Uwe Schindler 2011-01-20 00:37:40 +00:00
parent 0a30dcd945
commit ca0598b3e7
1 changed files with 3 additions and 0 deletions

View File

@ -209,6 +209,9 @@ public abstract class AnalysisRequestHandlerBase extends RequestHandlerBase {
new SorterTemplate() { new SorterTemplate() {
@Override @Override
protected void swap(int i, int j) { protected void swap(int i, int j) {
final int p = positions[i];
positions[i] = positions[j];
positions[j] = p;
Collections.swap(tokens, i, j); Collections.swap(tokens, i, j);
} }