]> git.bitcoin.ninja Git - rust-lightning/commitdiff
Disable fuzzing-reachable debug assertion
authorMatt Corallo <git@bluematt.me>
Sun, 24 Dec 2023 17:12:18 +0000 (17:12 +0000)
committerMatt Corallo <git@bluematt.me>
Fri, 2 Feb 2024 18:04:51 +0000 (18:04 +0000)
Because of txid conflicts, a txid can match both a local and remote
commitment transaction when fuzzing. Thus, we disable this
assertion when fuzzing.

lightning/src/chain/channelmonitor.rs

index e65b54f57013c58df60414c577e518254f17241b..55b7b503fdb06b39e59358eedf917ad684e2147d 100644 (file)
@@ -3679,6 +3679,7 @@ impl<Signer: WriteableEcdsaChannelSigner> ChannelMonitorImpl<Signer> {
                                                claimable_outpoints.append(&mut new_outpoints);
                                                if new_outpoints.is_empty() {
                                                        if let Some((mut new_outpoints, new_outputs)) = self.check_spend_holder_transaction(&tx, height, &block_hash, &logger) {
+                                                               #[cfg(not(fuzzing))]
                                                                debug_assert!(commitment_tx_to_counterparty_output.is_none(),
                                                                        "A commitment transaction matched as both a counterparty and local commitment tx?");
                                                                if !new_outputs.1.is_empty() {