You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We now also check that the serialization format has not changed and
suceed/fail to read the updates depending on whether `htlc_maximum_msat`
is present.
let old_chan_update_info_with_some:Vec<u8> = hex::decode("340004000000170201010402002a060800000000000004d2080909000000000000162e0a0d0c00040000000902040000000a0c0100").unwrap();
// Then check we can encode/decode ChannelInfo without ChannelUpdateInfo fields present.
2977
+
// Check we fail if htlc_maximum_msat is not present.
2978
+
let old_chan_update_info_with_none:Vec<u8> = hex::decode("2c0004000000170201010402002a060800000000000004d20801000a0d0c00040000000902040000000a0c0100").unwrap();
2979
+
let read_chan_update_info_res:Result<ChannelUpdateInfo,::ln::msgs::DecodeError> = ::util::ser::Readable::read(&mut old_chan_update_info_with_none.as_slice());
2980
+
assert!(read_chan_update_info_res.is_err());
2981
+
2982
+
// Check we can encode/decode ChannelInfo without ChannelUpdateInfo fields present.
0 commit comments