X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Fln%2Fchannelmanager.rs;h=148fdfa4854e0f906e6c45ad4299a15b26d2d36a;hb=1d7c4f663c41b13ed4a8b67d69c23136442a9b6b;hp=6116a49eee6088cc716cd8c60551ad463700bb79;hpb=3defcc896266f3d67848ce28981a756e971a3f0c;p=rust-lightning diff --git a/lightning/src/ln/channelmanager.rs b/lightning/src/ln/channelmanager.rs index 6116a49e..148fdfa4 100644 --- a/lightning/src/ln/channelmanager.rs +++ b/lightning/src/ln/channelmanager.rs @@ -21,7 +21,6 @@ use bitcoin::blockdata::block::BlockHeader; use bitcoin::blockdata::transaction::Transaction; use bitcoin::blockdata::constants::genesis_block; use bitcoin::network::constants::Network; -use bitcoin::util::hash::BitcoinHash; use bitcoin::hashes::{Hash, HashEngine}; use bitcoin::hashes::hmac::{Hmac, HmacEngine}; @@ -181,12 +180,15 @@ pub(super) enum HTLCFailReason { } /// payment_hash type, use to cross-lock hop +/// (C-not exported) as we just use [u8; 32] directly #[derive(Hash, Copy, Clone, PartialEq, Eq, Debug)] pub struct PaymentHash(pub [u8;32]); /// payment_preimage type, use to route payment between hop +/// (C-not exported) as we just use [u8; 32] directly #[derive(Hash, Copy, Clone, PartialEq, Eq, Debug)] pub struct PaymentPreimage(pub [u8;32]); /// payment_secret type, use to authenticate sender to the receiver and tie MPP HTLCs together +/// (C-not exported) as we just use [u8; 32] directly #[derive(Hash, Copy, Clone, PartialEq, Eq, Debug)] pub struct PaymentSecret(pub [u8;32]); @@ -724,7 +726,7 @@ impl ChannelManager { default_configuration: config.clone(), - genesis_hash: genesis_block(network).header.bitcoin_hash(), + genesis_hash: genesis_block(network).header.block_hash(), fee_estimator: fee_est, monitor, tx_broadcaster, @@ -2920,6 +2922,7 @@ impl /// If successful, will generate a UpdateHTLCs event, so you should probably poll /// PeerManager::process_events afterwards. /// Note: This API is likely to change! + /// (C-not exported) Cause its doc(hidden) anyway #[doc(hidden)] pub fn update_fee(&self, channel_id: [u8;32], feerate_per_kw: u32) -> Result<(), APIError> { let _ = self.total_consistency_lock.read().unwrap(); @@ -3060,7 +3063,7 @@ impl>, }