Gaukas Wang
7c77243b04
upstream: sync to 0.39.1
2023-10-26 22:47:22 -06:00
Marten Seemann
5dd6d91c11
send and track packets with ECN markings
2023-09-11 20:31:50 +07:00
Marten Seemann
090e505aa9
move GSO control message handling to the oobConn ( #4056 )
...
* move GSO control message handling to the oobConn
* disable OOB test on Windows
* improve GSO tests
* update ooConn.WritePacket comment
2023-08-31 00:49:27 -07:00
Gaukas Wang
95575f5fe7
break: update repo url [ci skip]
...
uTLS is not yet bumped to the new version, so this commit breaks the dependencies relationship by getting rid of the local replace.
2023-08-03 18:58:52 -06:00
Marten Seemann
2bcfe5bc4b
check for WSAEMSGSIZE errors when receiving UDP packets on Windows ( #3982 )
...
* check for WSAEMSGSIZE errors when receiving UDP packets on Windows
* check EMSGSIZE error on macOS
2023-07-20 20:31:57 -07:00
Marten Seemann
5b5ffa942b
pack packets into large buffers when GSO is available
2023-06-03 09:21:55 +03:00
Marten Seemann
af30cef57c
fix availability signaling of the send queue ( #3597 )
2022-10-22 12:09:40 +01:00
Rachel Chen
fd2c345152
sendQueue: ignore "datagram too large" error ( #3328 )
...
This commit introduces additional platform-dependent checking when the
kernel returns an error. Previously, the session is terminated when
PingFrame sends a discovery packet larger than the limit. With this
commit, the error is checked, and if it is "datagram too large", the
error is ignored.
Additionally,
1. This commit re-enables MTU discovery on Windows unless it
is disabled explicitly by user (Undo #3276 ),
2. Set IP_DONTFRAGMENT and IPV6_DONTFRAG with error checking on Windows,
and
3. Set IP_MTU_DISCOVERY to PMTUDISC_DO for both IPv4 and IPv6 on Linux
so that the kernel will return "message too long".
Fixes #3273 #3327
2022-02-20 00:21:32 -08:00
Marten Seemann
37337597bd
increase the size of the send queue
2021-01-20 14:45:18 +08:00
Marten Seemann
b81a6f875b
don't generate new packets when the send queue is full
2021-01-17 16:18:17 +08:00
Marten Seemann
f1c6421845
introduce an interface for the send queue, use a mock in session tests
2021-01-17 16:18:17 +08:00
Marten Seemann
89417ab5ca
simplify the connection, rename it to sendConn
2020-08-09 19:24:04 +07:00
Luke Tucker
3c1e597858
don't block sendQueue.Send() if the runloop already exited.
...
This can lead to a deadlock where session.shutdown() never exits
because it is blocked on a Send() but the sendQueue has exited due to
a write error.
2020-07-08 09:41:22 -04:00
Marten Seemann
d642bf9098
simplify content storage in packed packets
...
It's not necessary to store both the packetBuffer and the slice
containing the raw data in the packet.
2020-02-20 16:25:54 +07:00
Marten Seemann
93e724434b
make sure that all packets in the send queue are sent before closing
2020-02-17 13:41:00 +07:00
Marten Seemann
00c19f7241
implement a send queue to send packet asynchronously
2019-08-24 15:25:38 +07:00