@@ -927,6 +927,7 @@ pub struct UserConfig {
927
927
/// [`ChannelManager::send_payment_for_bolt12_invoice`]: crate::ln::channelmanager::ChannelManager::send_payment_for_bolt12_invoice
928
928
/// [`ChannelManager::abandon_payment`]: crate::ln::channelmanager::ChannelManager::abandon_payment
929
929
pub manually_handle_bolt12_invoices : bool ,
930
+ #[ cfg( dual_funding) ]
930
931
/// If this is set to `true`, dual-funded channels will be enabled.
931
932
///
932
933
/// Default value: `false`
@@ -981,6 +982,7 @@ impl Default for UserConfig {
981
982
manually_accept_inbound_channels : false ,
982
983
accept_intercept_htlcs : false ,
983
984
manually_handle_bolt12_invoices : false ,
985
+ #[ cfg( dual_funding) ]
984
986
enable_dual_funded_channels : false ,
985
987
enable_htlc_hold : false ,
986
988
hold_outbound_htlcs_at_next_hop : false ,
@@ -995,19 +997,32 @@ impl Default for UserConfig {
995
997
#[ cfg( fuzzing) ]
996
998
impl Readable for UserConfig {
997
999
fn read < R : crate :: io:: Read > ( reader : & mut R ) -> Result < Self , crate :: ln:: msgs:: DecodeError > {
1000
+ let channel_handshake_config = Readable :: read ( reader) ?;
1001
+ let channel_handshake_limits = Readable :: read ( reader) ?;
1002
+ let channel_config = Readable :: read ( reader) ?;
1003
+ let accept_forwards_to_priv_channels = Readable :: read ( reader) ?;
1004
+ let accept_inbound_channels = Readable :: read ( reader) ?;
1005
+ let manually_accept_inbound_channels = Readable :: read ( reader) ?;
1006
+ let accept_intercept_htlcs = Readable :: read ( reader) ?;
1007
+ let manually_handle_bolt12_invoices = Readable :: read ( reader) ?;
1008
+ let _enable_dual_funded_channels: bool = Readable :: read ( reader) ?;
1009
+ let hold_outbound_htlcs_at_next_hop = Readable :: read ( reader) ?;
1010
+ let enable_htlc_hold = Readable :: read ( reader) ?;
1011
+ let reject_inbound_splices = Readable :: read ( reader) ?;
998
1012
Ok ( Self {
999
- channel_handshake_config : Readable :: read ( reader) ?,
1000
- channel_handshake_limits : Readable :: read ( reader) ?,
1001
- channel_config : Readable :: read ( reader) ?,
1002
- accept_forwards_to_priv_channels : Readable :: read ( reader) ?,
1003
- accept_inbound_channels : Readable :: read ( reader) ?,
1004
- manually_accept_inbound_channels : Readable :: read ( reader) ?,
1005
- accept_intercept_htlcs : Readable :: read ( reader) ?,
1006
- manually_handle_bolt12_invoices : Readable :: read ( reader) ?,
1007
- enable_dual_funded_channels : Readable :: read ( reader) ?,
1008
- hold_outbound_htlcs_at_next_hop : Readable :: read ( reader) ?,
1009
- enable_htlc_hold : Readable :: read ( reader) ?,
1010
- reject_inbound_splices : Readable :: read ( reader) ?,
1013
+ channel_handshake_config,
1014
+ channel_handshake_limits,
1015
+ channel_config,
1016
+ accept_forwards_to_priv_channels,
1017
+ accept_inbound_channels,
1018
+ manually_accept_inbound_channels,
1019
+ accept_intercept_htlcs,
1020
+ manually_handle_bolt12_invoices,
1021
+ #[ cfg( dual_funding) ]
1022
+ enable_dual_funded_channels : _enable_dual_funded_channels,
1023
+ hold_outbound_htlcs_at_next_hop,
1024
+ enable_htlc_hold,
1025
+ reject_inbound_splices,
1011
1026
} )
1012
1027
}
1013
1028
}
0 commit comments