vacp2p / nim-libp2p

libp2p implementation in Nim
https://vacp2p.github.io/nim-libp2p/docs/
MIT License
249 stars 54 forks source link

move `header.length` check in `yamux` to original location #1069

Closed etan-status closed 6 months ago

etan-status commented 6 months ago

In original location, header.length > 0 check was inside the header.msgType == Data check. During #1045, it was accidentally moved outside and applied to all the header.msgType. Move back.

codecov-commenter commented 6 months ago

Codecov Report

Attention: Patch coverage is 75.00000% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 82.53%. Comparing base (48a3ac0) to head (2889dc0).

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/vacp2p/nim-libp2p/pull/1069/graphs/tree.svg?width=650&height=150&src=pr&token=M88zHaQffJ&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=vacp2p)](https://app.codecov.io/gh/vacp2p/nim-libp2p/pull/1069?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=vacp2p) ```diff @@ Coverage Diff @@ ## unstable #1069 +/- ## ============================================ + Coverage 82.50% 82.53% +0.02% ============================================ Files 91 91 Lines 15847 15847 ============================================ + Hits 13075 13079 +4 + Misses 2772 2768 -4 ``` | [Files](https://app.codecov.io/gh/vacp2p/nim-libp2p/pull/1069?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=vacp2p) | Coverage Δ | | |---|---|---| | [libp2p/muxers/yamux/yamux.nim](https://app.codecov.io/gh/vacp2p/nim-libp2p/pull/1069?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=vacp2p#diff-bGlicDJwL211eGVycy95YW11eC95YW11eC5uaW0=) | `84.53% <75.00%> (ø)` | | ... and [2 files with indirect coverage changes](https://app.codecov.io/gh/vacp2p/nim-libp2p/pull/1069/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=vacp2p)