From 9ca5de00f0a4cd1cfabcc085a600945d00ee77a0 Mon Sep 17 00:00:00 2001 From: Kelvin Tan Date: Mon, 17 May 2004 13:41:03 +0000 Subject: [PATCH] First filter gets modified if operation is an AND (which is terrible if its a cached filter and not a throw-away one). Patch by Rick Mann (rmann at keepmedia.com). git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@150982 13f79535-47bb-0310-9956-ffa450edef68 --- .../src/java/org/apache/lucene/misc/ChainedFilter.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sandbox/contributions/miscellaneous/src/java/org/apache/lucene/misc/ChainedFilter.java b/sandbox/contributions/miscellaneous/src/java/org/apache/lucene/misc/ChainedFilter.java index e0816d55cc6..057375901cd 100644 --- a/sandbox/contributions/miscellaneous/src/java/org/apache/lucene/misc/ChainedFilter.java +++ b/sandbox/contributions/miscellaneous/src/java/org/apache/lucene/misc/ChainedFilter.java @@ -174,7 +174,7 @@ public class ChainedFilter extends Filter */ if (logic == AND) { - result = chain[i].bits(reader); + result = chain[i].bits(reader).clone(); ++i; } else @@ -209,7 +209,7 @@ public class ChainedFilter extends Filter */ if (logic[0] == AND) { - result = chain[i].bits(reader); + result = chain[i].bits(reader).clone(); ++i; } else