speed-up search by starting at own height

This commit is contained in:
ThomasV 2017-07-19 16:28:17 +02:00
parent 7a8f337d28
commit 97343d95e5
1 changed files with 2 additions and 1 deletions

View File

@ -993,7 +993,8 @@ class Network(util.DaemonThread):
interface.mode = 'backward'
interface.bad = height
interface.bad_header = header
self.request_header(interface, height - 1) # should be max(heights)
tip = max([x.height() for x in self.blockchains.values()])
self.request_header(interface, tip)
def blockchain(self):
if self.interface and self.interface.blockchain is not None: