projects
/
rust-lightning
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Expose test_process_background_events
[rust-lightning]
/
lightning
/
src
/
ln
/
msgs.rs
diff --git
a/lightning/src/ln/msgs.rs
b/lightning/src/ln/msgs.rs
index 03897324150a2ffc8150502c184ff2c71367a916..eec1a053802fd7476ce1b43f0518b4ef339c1dfb 100644
(file)
--- a/
lightning/src/ln/msgs.rs
+++ b/
lightning/src/ln/msgs.rs
@@
-483,6
+483,17
@@
impl Readable for Result<NetAddress, u8> {
}
}
}
}
+impl Readable for NetAddress {
+ fn read<R: Read>(reader: &mut R) -> Result<NetAddress, DecodeError> {
+ match Readable::read(reader) {
+ Ok(Ok(res)) => Ok(res),
+ Ok(Err(_)) => Err(DecodeError::UnknownVersion),
+ Err(e) => Err(e),
+ }
+ }
+}
+
+
/// The unsigned part of a node_announcement
#[derive(Clone, Debug, PartialEq)]
pub struct UnsignedNodeAnnouncement {
/// The unsigned part of a node_announcement
#[derive(Clone, Debug, PartialEq)]
pub struct UnsignedNodeAnnouncement {