projects
/
rust-lightning
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #2025 from TheBlueMatt/2023-02-no-pub-genesis-hashes
[rust-lightning]
/
fuzz
/
src
/
router.rs
diff --git
a/fuzz/src/router.rs
b/fuzz/src/router.rs
index a30c7d28af4931230a9384f71ece64afdc8b6429..93de35c5d094783d8bdc4e9b6c6a935b39088f34 100644
(file)
--- a/
fuzz/src/router.rs
+++ b/
fuzz/src/router.rs
@@
-24,7
+24,6
@@
use lightning::util::ser::Readable;
use bitcoin::hashes::Hash;
use bitcoin::secp256k1::PublicKey;
use bitcoin::network::constants::Network;
use bitcoin::hashes::Hash;
use bitcoin::secp256k1::PublicKey;
use bitcoin::network::constants::Network;
-use bitcoin::blockdata::constants::genesis_block;
use crate::utils::test_logger;
use crate::utils::test_logger;
@@
-99,12
+98,12
@@
impl<Out: test_logger::Output> UtxoLookup for FuzzChainSource<'_, '_, Out> {
&[1, _] => UtxoResult::Sync(Err(UtxoLookupError::UnknownTx)),
&[2, _] => {
let future = UtxoFuture::new();
&[1, _] => UtxoResult::Sync(Err(UtxoLookupError::UnknownTx)),
&[2, _] => {
let future = UtxoFuture::new();
- future.resolve(self.net_graph, Ok(txo_res));
+ future.resolve
_without_forwarding
(self.net_graph, Ok(txo_res));
UtxoResult::Async(future.clone())
},
&[3, _] => {
let future = UtxoFuture::new();
UtxoResult::Async(future.clone())
},
&[3, _] => {
let future = UtxoFuture::new();
- future.resolve(self.net_graph, Err(UtxoLookupError::UnknownTx));
+ future.resolve
_without_forwarding
(self.net_graph, Err(UtxoLookupError::UnknownTx));
UtxoResult::Async(future.clone())
},
&[4, _] => {
UtxoResult::Async(future.clone())
},
&[4, _] => {
@@
-189,7
+188,7
@@
pub fn do_test<Out: test_logger::Output>(data: &[u8], out: Out) {
let logger = test_logger::TestLogger::new("".to_owned(), out);
let our_pubkey = get_pubkey!();
let logger = test_logger::TestLogger::new("".to_owned(), out);
let our_pubkey = get_pubkey!();
- let net_graph = NetworkGraph::new(
genesis_block(Network::Bitcoin).header.block_hash()
, &logger);
+ let net_graph = NetworkGraph::new(
Network::Bitcoin
, &logger);
let chain_source = FuzzChainSource {
input: Arc::clone(&input),
net_graph: &net_graph,
let chain_source = FuzzChainSource {
input: Arc::clone(&input),
net_graph: &net_graph,