From: Elias Rohrer Date: Wed, 18 Sep 2024 07:39:50 +0000 (+0200) Subject: `rustfmt`: Run on `util/fuzz_wrappers.rs` X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=8fb3c3f16e8987edbb6cc37d2291d9c88e3d0be3;p=rust-lightning `rustfmt`: Run on `util/fuzz_wrappers.rs` --- diff --git a/lightning/src/util/fuzz_wrappers.rs b/lightning/src/util/fuzz_wrappers.rs index dec3d8f65..6475065b8 100644 --- a/lightning/src/util/fuzz_wrappers.rs +++ b/lightning/src/util/fuzz_wrappers.rs @@ -8,19 +8,17 @@ // licenses. macro_rules! hash_to_message { - ($slice: expr) => { + ($slice: expr) => {{ + #[cfg(not(fuzzing))] { - #[cfg(not(fuzzing))] - { - ::bitcoin::secp256k1::Message::from_digest_slice($slice).unwrap() - } - #[cfg(fuzzing)] - { - match ::bitcoin::secp256k1::Message::from_digest_slice($slice) { - Ok(msg) => msg, - Err(_) => ::bitcoin::secp256k1::Message::from_digest([1; 32]) - } + ::bitcoin::secp256k1::Message::from_digest_slice($slice).unwrap() + } + #[cfg(fuzzing)] + { + match ::bitcoin::secp256k1::Message::from_digest_slice($slice) { + Ok(msg) => msg, + Err(_) => ::bitcoin::secp256k1::Message::from_digest([1; 32]), } } - } + }}; }