Check ValidForBlockInclusion in mpool
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
This commit is contained in:
parent
56d419e906
commit
aacfcba400
@ -317,6 +317,10 @@ func (mp *MessagePool) checkMessage(m *types.SignedMessage) error {
|
|||||||
return xerrors.Errorf("mpool message too large (%dB): %w", m.Size(), ErrMessageTooBig)
|
return xerrors.Errorf("mpool message too large (%dB): %w", m.Size(), ErrMessageTooBig)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if err := m.Message.ValidForBlockInclusion(0); err != nil {
|
||||||
|
return xerrors.Errorf("message not valid for block inclusion: %d", err)
|
||||||
|
}
|
||||||
|
|
||||||
if m.Message.To == address.Undef {
|
if m.Message.To == address.Undef {
|
||||||
return ErrInvalidToAddr
|
return ErrInvalidToAddr
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user