aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2019-04-29 15:03:44 -0400
committerMarcoFalke <falke.marco@gmail.com>2019-04-29 15:03:51 -0400
commitce6762030f814bc737bb0a097c17201e0b2edbc5 (patch)
treeeb113be466919524ba11bf922f7ec28d6b92bbe7
parent8da1aa471eb9f062c99c3134d6151961619e9da5 (diff)
parent9f9db39041d87c937f457b7f55f1def55c4ad6b3 (diff)
downloadbitcoin-ce6762030f814bc737bb0a097c17201e0b2edbc5.tar.xz
Merge #15897: QA/mininode: Send all headers upfront in send_blocks_and_test to avoid sending an unconnected one
9f9db39041 QA/mininode: Send all headers upfront in send_blocks_and_test to avoid sending an unconnected one (Luke Dashjr) Pull request description: While this doesn't currently trigger any problems, the network protocol does expect headers to be sent connectable in normal circumstances, and if too many are sent out of order will disconnect the peer. ACKs for commit 9f9db3: Tree-SHA512: 25b88718e4ba3d31aed2de7ece23fab9a0737fd6536c5e618ea8eb5a3a217dab0dffaebc4892df7993bcea7efb7c4fb5085fabebe99535b8f7fdde3c19df54ff
-rwxr-xr-xtest/functional/test_framework/mininode.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/functional/test_framework/mininode.py b/test/functional/test_framework/mininode.py
index 7a063ac526..11ea968257 100755
--- a/test/functional/test_framework/mininode.py
+++ b/test/functional/test_framework/mininode.py
@@ -531,7 +531,7 @@ class P2PDataStore(P2PInterface):
for b in blocks:
self.send_message(msg_block(block=b))
else:
- self.send_message(msg_headers([CBlockHeader(blocks[-1])]))
+ self.send_message(msg_headers([CBlockHeader(block) for block in blocks]))
wait_until(lambda: blocks[-1].sha256 in self.getdata_requests, timeout=timeout, lock=mininode_lock)
if expect_disconnect: