electrum

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

commit 12a02a8a1e4fdef98a7ae61f32bed2c0bdba9921
parent 9897e41e68cd63a61d02267961b358c0d2444ad7
Author: Janus <ysangkok@gmail.com>
Date:   Tue, 17 Jul 2018 15:23:55 +0200

lnrouter: ignore duplicate channel announcement

Diffstat:
Melectrum/lnrouter.py | 3+++
1 file changed, 3 insertions(+), 0 deletions(-)

diff --git a/electrum/lnrouter.py b/electrum/lnrouter.py @@ -114,6 +114,9 @@ class ChannelDB(PrintError): short_channel_id = msg_payload['short_channel_id'] #self.print_error('channel announcement', binascii.hexlify(short_channel_id).decode("ascii")) channel_info = ChannelInfo(msg_payload) + if short_channel_id in self._id_to_channel_info: + self.print_error("IGNORING CHANNEL ANNOUNCEMENT, WE ALREADY KNOW THIS CHANNEL") + return self._id_to_channel_info[short_channel_id] = channel_info self._channels_for_node[channel_info.node_id_1].add(short_channel_id) self._channels_for_node[channel_info.node_id_2].add(short_channel_id)