Files
firezone/rust/connlib
Thomas Eizinger 081216a929 fix(connlib): don't drop unsent datagrams (#7768)
We introduced a regression in `connlib` in #7749 whereby queued but
unsent datagrams got dropped in case the socket was not ready to send
more data.

This happens because within `Io`, we pull each datagram one by one from
the iterator:
e60ec7144c/rust/connlib/tunnel/src/io.rs (L178-L188)

This function will send datagrams for as long as the socket is ready and
drop the iterator afterwards. This means the returned iterator MUST BE
lazy and "cancel-safe". This was the case prior to #7749 because
`datagrams` function used `iter_mut` and only cut off the to be sent
bytes when the next item got pulled from iterator. With #7749, the
entire `HashMap` got drained, thus dropping packets if `Io` didn't
manage to process the iterator in full.
2025-01-16 15:26:59 +00:00
..

Connlib

Firezone's connectivity library shared by all clients.

Building Connlib

You shouldn't need to build connlib directly; it's typically built as a dependency of one of the other Firezone components. See READMEs in those directories for relevant instructions.