p2p/discover: use rlp.DecodeBytes

release/1.0.1
Felix Lange 10 years ago
parent 2750ec47b7
commit eedbb1ee9a
  1. 2
      p2p/discover/udp.go

@ -413,7 +413,7 @@ func decodePacket(buf []byte) (packet, NodeID, []byte, error) {
default:
return nil, fromID, hash, fmt.Errorf("unknown type: %d", ptype)
}
err = rlp.Decode(bytes.NewReader(sigdata[1:]), req)
err = rlp.DecodeBytes(sigdata[1:], req)
return req, fromID, hash, err
}

Loading…
Cancel
Save