diff --git a/Makefile b/Makefile index c51fc72b..b872b042 100644 --- a/Makefile +++ b/Makefile @@ -27,7 +27,7 @@ test: soft-reset: @echo "Soft-resetting Onionr..." - rm -f onionr/data/blocks/*.dat onionr/data/*.db | true > /dev/null 2>&1 + rm -f onionr/data/blocks/*.dat onionr/data/*.db onionr/data/block-nonces.dat | true > /dev/null 2>&1 @./RUN-LINUX.sh version | grep -v "Failed" --color=always reset: diff --git a/onionr/communicator2.py b/onionr/communicator2.py index 1f2166ac..42be9e45 100755 --- a/onionr/communicator2.py +++ b/onionr/communicator2.py @@ -186,6 +186,10 @@ class OnionrCommunicatorDaemon: if blockHash in self.currentDownloading: logger.debug('ALREADY DOWNLOADING ' + blockHash) continue + if blockHash in self._core.getBlockList(): + logger.debug('%s is already saved' % (blockHash,)) + self.blockQueue.remove(blockHash) + continue self.currentDownloading.append(blockHash) logger.info("Attempting to download %s..." % blockHash) peerUsed = self.pickOnlinePeer() diff --git a/onionr/static-data/default_config.json b/onionr/static-data/default_config.json index c298c137..fcbf733e 100644 --- a/onionr/static-data/default_config.json +++ b/onionr/static-data/default_config.json @@ -57,8 +57,8 @@ "blockCacheTotal": 50000000 }, "peers":{ - "minimumScore": -1000, - "maxStoredPeers": 100, - "maxConnect": 3 + "minimumScore": -100, + "maxStoredPeers": 500, + "maxConnect": 5 } }