lightningd: make sure we correctly clear connections from connectd on error.

Without this, the connect command hangs in one of my branches.  This logic
is from the old days when gossipd handled connections, and we wanted
to make sure it didn't hang up on this client due to the error.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2019-04-16 12:52:21 +09:30
committed by neil saitug
parent 62e1423968
commit a552130d3d
2 changed files with 1 additions and 2 deletions

View File

@@ -41,6 +41,7 @@ changes.
- lightning-cli: arguments containing `"` now succeed, rather than causing JSON errors.
- protocol: handle lnd sending more messages before `reestablish`; don't fail channel, and handle older lnd's spurious empty commitments.
- Fixed `fundchannel` crash when we have many UTXOs and we skip unconfirmed ones.
- lightningd: fixed occasional hang on `connect` when peer had sent error.
### Security

View File

@@ -388,8 +388,6 @@ void channel_errmsg(struct channel *channel,
err_for_them,
tal_count(err_for_them), 0);
/* Make sure channel_fail_permanent doesn't tell connectd we died! */
channel->connected = false;
notify_disconnect(channel->peer->ld, &channel->peer->id);
/* BOLT #1: