Skip to content

Commit

Permalink
GH-1145: Backport NPE Fix
Browse files Browse the repository at this point in the history
Resolves #1145

**cherry-pick to 2.0.x, 1.3.x**
  • Loading branch information
garyrussell authored and artembilan committed Jun 27, 2019
1 parent 1171c00 commit 15ab184
Showing 1 changed file with 4 additions and 1 deletion.
Expand Up @@ -630,7 +630,10 @@ else if (KafkaMessageListenerContainer.this.getContainerProperties().isSyncCommi
};
}

private void seekPartitions(Collection<TopicPartition> partitions, boolean idle) {
private void seekPartitions(@Nullable Collection<TopicPartition> partitions, boolean idle) {
if (partitions == null) {
return;
}
Map<TopicPartition, Long> current = new HashMap<>();
for (TopicPartition topicPartition : partitions) {
current.put(topicPartition, ListenerConsumer.this.consumer.position(topicPartition));
Expand Down

0 comments on commit 15ab184

Please sign in to comment.