From: Matt Corallo Date: Tue, 21 May 2019 14:53:29 +0000 (-0400) Subject: Send trusted peer a sendheaders X-Git-Url: http://git.bitcoin.ninja/?a=commitdiff_plain;h=ae6fb9ffff43140a4dae319193265f349fa2d835;p=dnsseed-rust Send trusted peer a sendheaders --- diff --git a/src/main.rs b/src/main.rs index 3086731..2c4acee 100644 --- a/src/main.rs +++ b/src/main.rs @@ -230,6 +230,9 @@ fn make_trusted_conn(trusted_sockaddr: SocketAddr) { starting_height = ver.start_height; }, NetworkMessage::Verack => { + if let Err(_) = trusted_write.try_send(NetworkMessage::SendHeaders) { + return future::err(()); + } if let Err(_) = trusted_write.try_send(NetworkMessage::GetHeaders(GetHeadersMessage { version: 70015, locator_hashes: vec![unsafe { HIGHEST_HEADER.as_ref().unwrap() }.lock().unwrap().0.clone()],