From 5c2e9e8acfe83e0d716d7f6ddfbf41515b2d0f99 Mon Sep 17 00:00:00 2001 From: Shai Erera Date: Mon, 28 Apr 2014 14:40:07 +0000 Subject: [PATCH] add DocValuesProducer to the Set once for all fields git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1590659 13f79535-47bb-0310-9956-ffa450edef68 --- .../src/java/org/apache/lucene/index/ReadersAndUpdates.java | 2 +- lucene/core/src/java/org/apache/lucene/index/SegmentReader.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lucene/core/src/java/org/apache/lucene/index/ReadersAndUpdates.java b/lucene/core/src/java/org/apache/lucene/index/ReadersAndUpdates.java index 76b2d6629f1..b953c211f14 100644 --- a/lucene/core/src/java/org/apache/lucene/index/ReadersAndUpdates.java +++ b/lucene/core/src/java/org/apache/lucene/index/ReadersAndUpdates.java @@ -484,7 +484,7 @@ class ReadersAndUpdates { success = true; } finally { if (!success) { - // Advance only the nextWriteDocValuesGen so that a 2nd + // Advance only the nextWriteFieldInfosGen so that a 2nd // attempt to write will write to a new file info.advanceNextWriteFieldInfosGen(); diff --git a/lucene/core/src/java/org/apache/lucene/index/SegmentReader.java b/lucene/core/src/java/org/apache/lucene/index/SegmentReader.java index 6f0f74d3605..7cab5af77b6 100644 --- a/lucene/core/src/java/org/apache/lucene/index/SegmentReader.java +++ b/lucene/core/src/java/org/apache/lucene/index/SegmentReader.java @@ -189,8 +189,8 @@ public final class SegmentReader extends AtomicReader { DocValuesProducer dvp = segDocValues.getDocValuesProducer(gen, si, IOContext.READ, dir, dvFormat, infos); for (FieldInfo fi : infos) { dvProducersByField.put(fi.name, dvp); - dvProducers.add(dvp); } + dvProducers.add(dvp); } dvGens.addAll(genInfos.keySet());