tsend another banner request on reconnect - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit 3cc382b7a0c48fc13d7cd883455c15b0ee894d85 DIR parent 4038b81a2239fd85b89f3d6124d01f02379ca475 HTML Author: thomasv <thomasv@gitorious> Date: Mon, 22 Oct 2012 15:01:13 +0200 send another banner request on reconnect Diffstat: M lib/wallet.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) --- DIR diff --git a/lib/wallet.py b/lib/wallet.py t@@ -831,7 +831,7 @@ class WalletSynchronizer(threading.Thread): self.interface = self.wallet.interface self.interface.register_channel('synchronizer') self.wallet.interface.register_callback('connected', self.wallet.init_up_to_date) - + self.wallet.interface.register_callback('connected', lambda: self.interface.send([('server.banner',[])],'synchronizer') ) def synchronize_wallet(self): new_addresses = self.wallet.synchronize() t@@ -858,9 +858,10 @@ class WalletSynchronizer(threading.Thread): def run(self): + # request banner, because 'connected' event happends before this thread is started + self.interface.send([('server.banner',[])],'synchronizer') # subscriptions - self.interface.send([('server.banner',[])],'synchronizer') self.interface.send([('blockchain.numblocks.subscribe',[])], 'synchronizer') self.interface.send([('server.peers.subscribe',[])],'synchronizer') self.subscribe_to_addresses(self.wallet.all_addresses())