Skip to content

Commit 2a20c1f

Browse files
committed
Correct ChannelManager in_flight_monitor_updates serialization
In e8854f9 we changed the type of `ChannelManager::in_flight_monitor_updates`, writing a legacy version and reading the new version as a new TLV field. Sadly, we spuriously marked the new TLV as `required`, breaking upgrade from 0.1. Here we fix the oversight by simply marking it `option`al.
1 parent c7c3973 commit 2a20c1f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lightning/src/ln/channelmanager.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12960,7 +12960,7 @@ where
1296012960
(13, htlc_onion_fields, optional_vec),
1296112961
(14, decode_update_add_htlcs_opt, option),
1296212962
(15, self.inbound_payment_id_secret, required),
12963-
(17, in_flight_monitor_updates, required),
12963+
(17, in_flight_monitor_updates, option),
1296412964
});
1296512965

1296612966
Ok(())
@@ -13503,7 +13503,7 @@ where
1350313503
(13, claimable_htlc_onion_fields, optional_vec),
1350413504
(14, decode_update_add_htlcs, option),
1350513505
(15, inbound_payment_id_secret, option),
13506-
(17, in_flight_monitor_updates, required),
13506+
(17, in_flight_monitor_updates, option),
1350713507
});
1350813508
let mut decode_update_add_htlcs = decode_update_add_htlcs.unwrap_or_else(|| new_hash_map());
1350913509
if fake_scid_rand_bytes.is_none() {

0 commit comments

Comments
 (0)