mempool: force broadcasting on addTX fail.

This commit is contained in:
Christopher Jeffrey 2017-02-07 13:56:30 -08:00
parent 256c449e68
commit d3f94dbc6a
No known key found for this signature in database
GPG Key ID: 8962AB9DE6666BBD
2 changed files with 3 additions and 3 deletions

View File

@ -1304,7 +1304,7 @@ Mempool.prototype.storeOrphan = function storeOrphan(tx, missing) {
this.logger.debug('Ignoring large orphan: %s', tx.txid());
if (!tx.hasWitness())
this.rejects.add(tx.hash());
return;
return [];
}
for (i = 0; i < missing.length; i++) {
@ -1312,7 +1312,7 @@ Mempool.prototype.storeOrphan = function storeOrphan(tx, missing) {
if (this.hasReject(prev)) {
this.logger.debug('Not storing orphan %s (rejected parents).', tx.txid());
this.rejects.add(tx.hash());
return;
return [];
}
}

View File

@ -2179,7 +2179,7 @@ Pool.prototype._handleTX = co(function* handleTX(peer, packet) {
throw err;
}
if (missing) {
if (missing && missing.length > 0) {
this.logger.debug(
'Requesting %d missing transactions (%s).',
missing.length, peer.hostname());