@@ -4462,6 +4462,7 @@ impl<Signer: Sign> Channel<Signer> {
4462
4462
}
4463
4463
/// Only fails in case of bad keys
4464
4464
fn send_commitment_no_status_check < L : Deref > ( & mut self , logger : & L ) -> Result < ( msgs:: CommitmentSigned , ChannelMonitorUpdate ) , ChannelError > where L :: Target : Logger {
4465
+ log_trace ! ( logger, "Updating HTLC state for a newly-sent commitment_signed..." ) ;
4465
4466
// We can upgrade the status of some HTLCs that are waiting on a commitment, even if we
4466
4467
// fail to generate this, we still are at least at a position where upgrading their status
4467
4468
// is acceptable.
@@ -4470,19 +4471,22 @@ impl<Signer: Sign> Channel<Signer> {
4470
4471
Some ( InboundHTLCState :: AwaitingAnnouncedRemoteRevoke ( forward_info. clone ( ) ) )
4471
4472
} else { None } ;
4472
4473
if let Some ( state) = new_state {
4474
+ log_trace ! ( logger, " ...promoting inbound AwaitingRemoteRevokeToAnnounce {} to AwaitingAnnouncedRemoteRevoke" , log_bytes!( htlc. payment_hash. 0 ) ) ;
4473
4475
htlc. state = state;
4474
4476
}
4475
4477
}
4476
4478
for htlc in self . pending_outbound_htlcs . iter_mut ( ) {
4477
4479
if let Some ( fail_reason) = if let & mut OutboundHTLCState :: AwaitingRemoteRevokeToRemove ( ref mut fail_reason) = & mut htlc. state {
4478
4480
Some ( fail_reason. take ( ) )
4479
4481
} else { None } {
4482
+ log_trace ! ( logger, " ...promoting outbound AwaitingRemoteRevokeToRemove {} to AwaitingRemovedRemoteRevoke" , log_bytes!( htlc. payment_hash. 0 ) ) ;
4480
4483
htlc. state = OutboundHTLCState :: AwaitingRemovedRemoteRevoke ( fail_reason) ;
4481
4484
}
4482
4485
}
4483
4486
if let Some ( ( feerate, update_state) ) = self . pending_update_fee {
4484
4487
if update_state == FeeUpdateState :: AwaitingRemoteRevokeToAnnounce {
4485
4488
debug_assert ! ( !self . is_outbound( ) ) ;
4489
+ log_trace ! ( logger, " ...promoting inbound AwaitingRemoteRevokeToAnnounce fee update {} to Committed" , feerate) ;
4486
4490
self . feerate_per_kw = feerate;
4487
4491
self . pending_update_fee = None ;
4488
4492
}
0 commit comments