]> git.bitcoin.ninja Git - rust-lightning/commit
Use `ChannelUnavailable` for a peer disconnecting not `MisuseError` 2022-01-fuzz-hashbrown
authorMatt Corallo <git@bluematt.me>
Sun, 15 Jan 2023 23:37:00 +0000 (23:37 +0000)
committerMatt Corallo <git@bluematt.me>
Sun, 15 Jan 2023 23:38:24 +0000 (23:38 +0000)
commitf9bafa6d0ee72a71985073e7c2d94ac28f8d689e
treefdf9898e34fa6fe9f327376df0b5bf80e2a2dcd2
parentfb5b427cba9286f32398b64d7192320cb8f826b1
Use `ChannelUnavailable` for a peer disconnecting not `MisuseError`

This fixes a crash in the `full_stack_target` fuzz test (found by
Chaincode's generous fuzzing infrastructure!) but ultimately is a
better error code - a peer disconnecting before we can fund a
channel isn't a "misuse error" its an unavailable channel.
fuzz/src/full_stack.rs
lightning/src/ln/channelmanager.rs