Skip to content

Commit

Permalink
Dbstate can be nil when a follower of a stalled network intereacts with
Browse files Browse the repository at this point in the history
a leader who rebooted:
  • Loading branch information
Emyrk committed Jan 17, 2018
1 parent e75c7cf commit 53b14a1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions state/stateConsensus.go
Expand Up @@ -1490,6 +1490,10 @@ func (s *State) ProcessEOM(dbheight uint32, msg interfaces.IMsg) bool {
case s.CurrentMinute < 10:
if s.CurrentMinute == 1 {
dbstate := s.GetDBState(dbheight - 1)
// Panic had arose when leaders would reboot and the follower was on a future minute
if dbstate == nil {
return false
}
if !dbstate.Saved {
dbstate.ReadyToSave = true
}
Expand Down

0 comments on commit 53b14a1

Please sign in to comment.