fxied validateHash

This commit is contained in:
Kevin Froman 2018-01-28 16:41:49 -06:00
parent c6ad487c79
commit 1b0d575575
No known key found for this signature in database
GPG Key ID: 0D414D0FE405B63B

View File

@ -103,11 +103,8 @@ class OnionrCommunicate:
if lastDB != currentDB:
logger.debug('Fetching hash from ' + i + ' - ' + currentDB + ' current hash.')
blocks += self.performGet('getBlockHashes', i)
if currentDB != lastDB:
if self._utils.validateHash(currentDB):
self._core.setPeerInfo(i, "blockDBHash", currentDB)
else:
logger.warn("Peer " + i + " returned malformed hash")
logger.debug('BLOCKS: \n' + blocks)
blockList = blocks.split('\n')
for i in blockList: