electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 35878b437ac88bedbf49c17ea004885a7859aaa6
parent 0dfaf9b97013ce9221bc8589ad806e52643e727d
Author: ThomasV <thomasv@electrum.org>
Date:   Fri, 19 Jan 2018 15:48:20 +0100

network: send version first

Diffstat:
Mlib/network.py | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/network.py b/lib/network.py @@ -306,6 +306,9 @@ class Network(util.DaemonThread): # Resend unanswered requests requests = self.unanswered_requests.values() self.unanswered_requests = {} + if self.interface.ping_required(): + params = [ELECTRUM_VERSION, PROTOCOL_VERSION] + self.queue_request('server.version', params, self.interface) for request in requests: message_id = self.queue_request(request[0], request[1]) self.unanswered_requests[message_id] = request @@ -314,9 +317,6 @@ class Network(util.DaemonThread): self.queue_request('server.peers.subscribe', []) self.request_fee_estimates() self.queue_request('blockchain.relayfee', []) - if self.interface.ping_required(): - params = [ELECTRUM_VERSION, PROTOCOL_VERSION] - self.queue_request('server.version', params, self.interface) for h in self.subscribed_addresses: self.queue_request('blockchain.scripthash.subscribe', [h])