network: add getblocks message parsing

It has identical structure to the `getheaders`.
This commit is contained in:
Roman Khimov 2019-08-29 19:43:23 +03:00
parent b5813efb29
commit 2d94a1e337

View file

@ -201,6 +201,8 @@ func (m *Message) decodePayload(r io.Reader) error {
if err := p.DecodeBinary(buf); err != nil {
return err
}
case CMDGetBlocks:
fallthrough
case CMDGetHeaders:
p = &payload.GetBlocks{}
if err := p.DecodeBinary(buf); err != nil {