From a83d337f410a31a27b857e0f3125f1f5409fcb82 Mon Sep 17 00:00:00 2001 From: Michael Busch Date: Fri, 21 Aug 2009 16:47:48 +0000 Subject: [PATCH] LUCENE-1832: Remove unnecessary null check in TermInfosReader. git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@806637 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/org/apache/lucene/index/TermInfosReader.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/java/org/apache/lucene/index/TermInfosReader.java b/src/java/org/apache/lucene/index/TermInfosReader.java index 7ca4f1048c1..47b6fabf5d3 100644 --- a/src/java/org/apache/lucene/index/TermInfosReader.java +++ b/src/java/org/apache/lucene/index/TermInfosReader.java @@ -246,7 +246,7 @@ final class TermInfosReader { if (size == 0) return null; SegmentTermEnum enumerator = getThreadResources().termEnum; - if (enumerator != null && enumerator.term() != null && + if (enumerator.term() != null && position >= enumerator.position && position < (enumerator.position + totalIndexInterval)) return scanEnum(enumerator, position); // can avoid seek