Skip to content
This repository has been archived by the owner on May 13, 2019. It is now read-only.

Commit

Permalink
Protect against nil messages, which happen very infrequently.
Browse files Browse the repository at this point in the history
The root cause of nil messages has not been diagnosed.

Run "go fmt"
  • Loading branch information
rrh committed Dec 1, 2015
1 parent 1a8639a commit 2027a51
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion consumergroup/consumer_group.go
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,9 @@ partitionConsumerLoop:
break partitionConsumerLoop

case messages <- message:
lastOffset = message.Offset
if message != nil {
lastOffset = message.Offset
}
continue partitionConsumerLoop
}
}
Expand Down

0 comments on commit 2027a51

Please sign in to comment.