URI: 
       tfix: reorgs - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit 1ee70f798e58254e00e4af40c806ef0e1d053018
   DIR parent 63f14f6ab2d4b306dd664e56560e434e1d322c5b
  HTML Author: ThomasV <thomasv@electrum.org>
       Date:   Tue, 23 May 2017 14:51:44 +0200
       
       fix: reorgs
       
       Diffstat:
         M lib/network.py                      |      11 ++++-------
       
       1 file changed, 4 insertions(+), 7 deletions(-)
       ---
   DIR diff --git a/lib/network.py b/lib/network.py
       t@@ -829,14 +829,11 @@ class Network(util.DaemonThread):
                        next_height = (interface.bad + interface.good) // 2
                elif interface.mode == 'default':
                    if can_connect:
       -                if height > self.get_local_height():
       -                    self.blockchain.save_header(header)
       -                    self.notify('updated')
       -                if height < interface.tip:
       -                    next_height = height + 1
       -                else:
       -                    next_height = None
       +                self.blockchain.save_header(header)
       +                self.notify('updated')
       +                next_height = height + 1 if height < interface.tip else None
                    else:
       +                interface.print_error("cannot connect %d"% height)
                        interface.mode = 'backward'
                        interface.bad = height
                        next_height = height - 1