Skip to content

Commit d26e490

Browse files
committed
pytest: fix broken message in test_even_sendcustommsg.
We can stop listening on the incoming peer while we are closing, so we don't notice if they close: ``` ['lightningd-2 2025-09-03T09:48:19.555Z **BROKEN** 0266e4598d1d3c415f572a8488830b60f7e744ed9235eb0b1ba93283b315c03518-connectd: Peer did not close, forcing close', 'lightningd-2 2025-09-03T09:48:22.918Z **BROKEN** 0266e4598d1d3c415f572a8488830b60f7e744ed9235eb0b1ba93283b315c03518-connectd: Peer did not close, forcing close'] =========================== short test summary info ============================ ERROR tests/test_misc.py::test_even_sendcustommsg - ValueError: ``` Signed-off-by: Rusty Russell <[email protected]>
1 parent 385e476 commit d26e490

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

connectd/multiplex.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1082,8 +1082,10 @@ static struct io_plan *write_to_peer(struct io_conn *peer_conn,
10821082
/* Still nothing to send? */
10831083
if (!msg) {
10841084
/* Draining? We're done when subds are done. */
1085-
if (peer->draining && tal_count(peer->subds) == 0)
1085+
if (peer->draining && tal_count(peer->subds) == 0) {
1086+
io_wake(&peer->peer_in);
10861087
return io_sock_shutdown(peer_conn);
1088+
}
10871089

10881090
/* If they want us to send gossip, do so now. */
10891091
if (!peer->draining)

0 commit comments

Comments
 (0)