net: enable segwit compact blocks.
This commit is contained in:
parent
62ef5ea7f4
commit
c3a9b7378f
@ -2378,8 +2378,9 @@ Peer.prototype.sendReject = function sendReject(code, reason, obj) {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
Peer.prototype.sendCompact = function sendCompact() {
|
Peer.prototype.sendCompact = function sendCompact() {
|
||||||
|
var version = this.options.witness ? 2 : 1;
|
||||||
this.logger.info('Initializing compact blocks (%s).', this.hostname);
|
this.logger.info('Initializing compact blocks (%s).', this.hostname);
|
||||||
return this.send(new packets.SendCmpctPacket(0, 1));
|
return this.send(new packets.SendCmpctPacket(0, version));
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user