mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
* fix disconnect reason encoding * move disconnect to own file * add encoding test for 0x80 in list * rlp([0u8]) is a good test case to have because it is the RLP encoding of a DisconnectRequested p2p message * fix disconnect encoding and decoding * directly decode the disconnect id to handle the 0x80 case of DisconnectRequested * the previous manual snappy encoding / decoding was incorrect - a snappy encoded disconnect message is 4 bytes, not 3 bytes. The tests and implementation are changed to reflect this. * fix p2p message decoding * had a similar issue to disconnect reason decoding where it would not handle a 0x80 message id * make invalid rlp header case more explicit * cargo fmt