aboutsummaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorRoman Arutyunyan <arut@nginx.com>2023-08-14 09:21:27 +0400
committerRoman Arutyunyan <arut@nginx.com>2023-08-14 09:21:27 +0400
commiteeb8a9f56f727d2543c8ae7feae0de784e329b27 (patch)
treea3b6dbde4411df979e93ca7df075cb15a5156850 /src/core
parent58fc5e2830a0fa70810005ca03fdb9a531719696 (diff)
downloadnginx-eeb8a9f56f727d2543c8ae7feae0de784e329b27.tar.gz
nginx-eeb8a9f56f727d2543c8ae7feae0de784e329b27.zip
QUIC: path MTU discovery.
MTU selection starts by doubling the initial MTU until the first failure. Then binary search is used to find the path MTU.
Diffstat (limited to 'src/core')
-rw-r--r--src/core/ngx_connection.c5
-rw-r--r--src/core/ngx_connection.h3
2 files changed, 7 insertions, 1 deletions
diff --git a/src/core/ngx_connection.c b/src/core/ngx_connection.c
index 10f4d9b91..75809d9ad 100644
--- a/src/core/ngx_connection.c
+++ b/src/core/ngx_connection.c
@@ -1583,6 +1583,10 @@ ngx_connection_error(ngx_connection_t *c, ngx_err_t err, char *text)
}
#endif
+ if (err == NGX_EMSGSIZE && c->log_error == NGX_ERROR_IGNORE_EMSGSIZE) {
+ return 0;
+ }
+
if (err == 0
|| err == NGX_ECONNRESET
#if (NGX_WIN32)
@@ -1600,6 +1604,7 @@ ngx_connection_error(ngx_connection_t *c, ngx_err_t err, char *text)
{
switch (c->log_error) {
+ case NGX_ERROR_IGNORE_EMSGSIZE:
case NGX_ERROR_IGNORE_EINVAL:
case NGX_ERROR_IGNORE_ECONNRESET:
case NGX_ERROR_INFO:
diff --git a/src/core/ngx_connection.h b/src/core/ngx_connection.h
index c90f0ea50..84dd80442 100644
--- a/src/core/ngx_connection.h
+++ b/src/core/ngx_connection.h
@@ -97,7 +97,8 @@ typedef enum {
NGX_ERROR_ERR,
NGX_ERROR_INFO,
NGX_ERROR_IGNORE_ECONNRESET,
- NGX_ERROR_IGNORE_EINVAL
+ NGX_ERROR_IGNORE_EINVAL,
+ NGX_ERROR_IGNORE_EMSGSIZE
} ngx_connection_log_error_e;