executor is always notified about ignored getheaders
This commit is contained in:
parent
8cc045c92b
commit
8ecfc9368d
|
@ -109,10 +109,10 @@ impl<T, U, V> LocalNode<T, U, V> where T: SynchronizationTaskExecutor + PeersCon
|
|||
trace!(target: "sync", "Got `getheaders` message from peer#{}", peer_index);
|
||||
|
||||
// do not serve getheaders requests until we are synchronized
|
||||
// TODO: uncomment this, and notify p2p module about ignored request
|
||||
//if self.client.lock().state().is_synchronizing() {
|
||||
//return;
|
||||
//}
|
||||
if self.client.lock().state().is_synchronizing() {
|
||||
self.executor.lock().execute(SynchronizationTask::Ignore(peer_index, id));
|
||||
return;
|
||||
}
|
||||
|
||||
// simulating bitcoind for passing tests: if we are in nearly-saturated state
|
||||
// and peer, which has just provided a new blocks to us, is asking for headers
|
||||
|
|
Loading…
Reference in New Issue