diff --git a/CHANGELOG.md b/CHANGELOG.md index edb07661b0b2..ba3e940dc762 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,6 +23,7 @@ changes. - Plugin: `pay` no longer crashes on timeout. - Plugin: `disconnect` notifier now called if remote side disconnects. +- channeld: ignore, and simply try reconnecting if lnd sends "sync error". ### Security diff --git a/common/peer_failed.c b/common/peer_failed.c index cc4051dc5a41..c7daadc0141f 100644 --- a/common/peer_failed.c +++ b/common/peer_failed.c @@ -56,10 +56,22 @@ void peer_failed_received_errmsg(struct per_peer_state *pps, { static const struct channel_id all_channels; u8 *msg; + bool sync_error; + + /* <+roasbeef> rusty: sync error can just be a timing thing + * <+roasbeef> andn doesn't always mean that we can't continue forwrd, + * or y'all sent the wrong info + */ + /* So while LND is sitting in the corner eating paint, back off. */ + sync_error = strstr(desc, "sync error"); + if (sync_error) + status_unusual("Peer said '%s' so we'll come back later", + desc); if (!channel_id) channel_id = &all_channels; - msg = towire_status_peer_error(NULL, channel_id, desc, false, pps, NULL); + msg = towire_status_peer_error(NULL, channel_id, desc, sync_error, pps, + NULL); peer_billboard(true, "Received error from peer: %s", desc); peer_fatal_continue(take(msg), pps); }