URI: 
       tlnbase: infinite amount of incoming payments - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit 73a17c93eec0badb918137c47f2b688c2dc874b8
   DIR parent 6173c2d7a7777c20554d469a4c98168b75bc1cab
  HTML Author: Janus <ysangkok@gmail.com>
       Date:   Mon, 14 May 2018 15:28:18 +0200
       
       lnbase: infinite amount of incoming payments
       
       Diffstat:
         M lib/lnbase.py                       |       6 ++++--
       
       1 file changed, 4 insertions(+), 2 deletions(-)
       ---
   DIR diff --git a/lib/lnbase.py b/lib/lnbase.py
       t@@ -1003,8 +1003,10 @@ class Peer(PrintError):
            async def receive_commitment_revoke_ack(self, chan, expected_received_sat, payment_preimage):
                def derive_and_incr():
                    nonlocal chan
       -            last_secret = get_per_commitment_secret_from_seed(chan.local_state.per_commitment_secret_seed, 2**48-chan.local_state.ctn-1)
       -            next_secret = get_per_commitment_secret_from_seed(chan.local_state.per_commitment_secret_seed, 2**48-chan.local_state.ctn-(2 if chan.local_state.ctn < 2 else 0)-1)
       +            last_small_num = chan.local_state.ctn
       +            next_small_num = last_small_num + 2
       +            last_secret = get_per_commitment_secret_from_seed(chan.local_state.per_commitment_secret_seed, 2**48-last_small_num-1)
       +            next_secret = get_per_commitment_secret_from_seed(chan.local_state.per_commitment_secret_seed, 2**48-next_small_num-1)
                    next_point = secret_to_pubkey(int.from_bytes(next_secret, 'big'))
                    chan = chan._replace(
                        local_state=chan.local_state._replace(