diff options
| author | Sergey Kandaurov <pluknet@nginx.com> | 2021-09-22 14:01:18 +0300 |
|---|---|---|
| committer | Sergey Kandaurov <pluknet@nginx.com> | 2021-09-22 14:01:18 +0300 |
| commit | 4e2e70b16cf1df40327d4633b8622e66a0986275 (patch) | |
| tree | cac54c88a8525ece4870170e7a5cfd1904285c47 /src/event | |
| parent | b2c8e690cee3c450ffb79438f291e639c7891502 (diff) | |
| download | nginx-4e2e70b16cf1df40327d4633b8622e66a0986275.tar.gz nginx-4e2e70b16cf1df40327d4633b8622e66a0986275.tar.bz2 | |
QUIC: set NGX_TCP_NODELAY_DISABLED for fake stream connections.
Notably, it is to avoid setting the TCP_NODELAY flag for QUIC streams
in ngx_http_upstream_send_response(). It is an invalid operation on
inherently SOCK_DGRAM sockets, which leads to QUIC connection close.
The change reduces diff to the default branch in stream content phase.
Diffstat (limited to 'src/event')
| -rw-r--r-- | src/event/quic/ngx_event_quic_streams.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/event/quic/ngx_event_quic_streams.c b/src/event/quic/ngx_event_quic_streams.c index 9473f99b4..7ad443eec 100644 --- a/src/event/quic/ngx_event_quic_streams.c +++ b/src/event/quic/ngx_event_quic_streams.c @@ -450,6 +450,7 @@ ngx_quic_create_stream(ngx_connection_t *c, uint64_t id) sc->local_sockaddr = c->local_sockaddr; sc->local_socklen = c->local_socklen; sc->number = ngx_atomic_fetch_add(ngx_connection_counter, 1); + sc->tcp_nodelay = NGX_TCP_NODELAY_DISABLED; sc->recv = ngx_quic_stream_recv; sc->send = ngx_quic_stream_send; |
