Skip to content

Commit 3c575db

Browse files
committed
f add note on the belt-and-suspenders force-write
1 parent 117b10e commit 3c575db

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lightning/src/ln/peer_handler.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1663,6 +1663,9 @@ where
16631663
Some(peer_mutex) => {
16641664
let mut peer = peer_mutex.lock().unwrap();
16651665
peer.awaiting_write_event = false;
1666+
// We go ahead and force at least one write here, because if we don't have any
1667+
// messages to send and the net driver thought we did that's weird, so they might
1668+
// also have a confused read-paused state that we should go ahead and clear.
16661669
self.do_attempt_write_data(descriptor, &mut peer, true);
16671670
},
16681671
};

0 commit comments

Comments
 (0)