ywelsch commented on a change in pull request #539: URL: https://github.com/apache/lucene/pull/539#discussion_r778845058
########## File path: lucene/core/src/java/org/apache/lucene/index/SegmentMerger.java ########## @@ -203,8 +203,13 @@ private void mergeTerms(SegmentWriteState segmentWriteState, SegmentReadState se // Use the merge instance in order to reuse the same IndexInput for all terms normsMergeInstance = norms.getMergeInstance(); } - try (FieldsConsumer consumer = codec.postingsFormat().fieldsConsumer(segmentWriteState)) { - consumer.merge(mergeState, normsMergeInstance); + try (FieldsConsumer consumer = + mergeState.mergeFieldInfos.hasIndexed() + ? codec.postingsFormat().fieldsConsumer(segmentWriteState) + : null) { + if (consumer != null) { + consumer.merge(mergeState, normsMergeInstance); + } Review comment: fixed in 3d8a60d -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org