Merge remote-tracking branch 'origin/consensus_refactor' into consensus_refactor_jae

This commit is contained in:
Jae Kwon
2015-12-14 09:33:11 -08:00
12 changed files with 650 additions and 754 deletions
+2 -3
View File
@@ -33,7 +33,7 @@ type State struct {
LastValidators *types.ValidatorSet
LastAppHash []byte
evc events.Fireable // typically an events.EventCache
evc *events.EventCache
}
func LoadState(db dbm.DB) *State {
@@ -81,8 +81,7 @@ func (s *State) Save() {
s.db.Set(stateKey, buf.Bytes())
}
// Implements events.Eventable. Typically uses events.EventCache
func (s *State) SetFireable(evc events.Fireable) {
func (s *State) SetEventCache(evc *events.EventCache) {
s.mtx.Lock()
defer s.mtx.Unlock()