mhw0 / libethc

Open-source Ethereum C library
https://mhw0.github.io/libethc/
MIT License
48 stars 9 forks source link

rlp: decode long hex #46

Closed zzzzzzch closed 2 months ago

zzzzzzch commented 2 months ago

Hi, I found that RLP decoding fails when parsing long encoded string, so I modified the eth_rlp_len function and unit-tested it with an EIP-1559 transaction. It seems to be working fine.

But there are two things I'm not sure about:

Besides, a free issue that could lead to memory leaks is fixed.

Please review the PR and feel free to comment. I'll fix it as soon as possible.

mhw0 commented 2 months ago

Hi @zzzzzzch Thank you so much for the PR! Reviewing the changes...