Merge pull request #1136 from nspcc-dev/neo3/consensus/fix

consensus: prevent `invalid message` panic
This commit is contained in:
Roman Khimov 2020-06-30 13:10:43 +03:00 committed by GitHub
commit 59d1013a8f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -283,7 +283,7 @@ func (s *service) OnPayload(cp *Payload) {
} }
// decode payload data into message // decode payload data into message
if cp.message == nil { if cp.message.payload == nil {
if err := cp.decodeData(); err != nil { if err := cp.decodeData(); err != nil {
log.Debug("can't decode payload data") log.Debug("can't decode payload data")
return return