Skip to content

Commit cd057b8

Browse files
whitslackrustyrussell
authored andcommitted
connectd: demote "Peer did not close, forcing close" to UNUSUAL
This message is logged when connectd tries to shut down a peer connection but the transmit buffer remains full for too long, maybe because the peer has crashed or has lost connectivity. Logging this message at the BROKEN level is inappropriate because BROKEN is intended to flag logic errors that imply incorrect code in CLN. The error in question here is actually a runtime error, which does not imply incorrect code (at least on our side), so demote the log message to the UNUSUAL level. (Even this is still probably too severe, as this message is logged rather more frequently than "unusual" would suggest.) Changelog-None Closes: #5678
1 parent 8229039 commit cd057b8

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

connectd/multiplex.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,7 @@ static void maybe_free_peer(struct peer *peer)
106106
* not reading, we have to give up. */
107107
static void close_peer_io_timeout(struct peer *peer)
108108
{
109-
/* BROKEN means we'll trigger CI if we see it, though it's possible */
110-
status_peer_broken(&peer->id, "Peer did not close, forcing close");
109+
status_peer_unusual(&peer->id, CI_UNEXPECTED "Peer did not close, forcing close");
111110
io_close(peer->to_peer);
112111
}
113112

0 commit comments

Comments
 (0)