Skip to content

Commit c5da558

Browse files
committed
macos: add TCP_FASTOPEN_FORCE_ENABLE
This is used to disable the backoff mechanism, otherwise TFO is basically unusable. Definition: https://github.com/apple/darwin-xnu/blob/2ff845c2e033bd0ff64b5b6aa6063a1f8f65aa32/bsd/netinet/tcp.h#L310 Related commits/PRs: zonyitoo/tokio-tfo#5, database64128/tfo-go@c980f6b
1 parent 973c3e1 commit c5da558

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/unix/bsd/apple/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -3657,6 +3657,8 @@ pub const TCP_KEEPINTVL: ::c_int = 0x101;
36573657
pub const TCP_KEEPCNT: ::c_int = 0x102;
36583658
/// Enable/Disable TCP Fastopen on this socket
36593659
pub const TCP_FASTOPEN: ::c_int = 0x105;
3660+
/// Disable/Enable TCP Fastopen backoff mechanism.
3661+
pub const TCP_FASTOPEN_FORCE_ENABLE: ::c_int = 0x218;
36603662

36613663
pub const SOL_LOCAL: ::c_int = 0;
36623664

0 commit comments

Comments
 (0)