summaryrefslogtreecommitdiffstats
path: root/ssl/d1_lib.c
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2014-12-01 11:13:15 +0000
committerMatt Caswell <matt@openssl.org>2014-12-03 09:38:10 +0000
commit6d41cbb63aa342665c5f60ea3579410331d656ee (patch)
tree327952ce83ea63b788421743c0a207a2b3d20fb3 /ssl/d1_lib.c
parent04a73c844f31e117cd22d5704f05a56ead7cef23 (diff)
The SSL_OP_NO_QUERY_MTU option is supposed to stop the mtu from being
automatically updated, and we should use the one provided instead. Unfortunately there are a couple of locations where this is not respected. Reviewed-by: Tim Hudson <tjh@openssl.org> (cherry picked from commit 001235778a6e9c645dc0507cad6092d99c9af8f5)
Diffstat (limited to 'ssl/d1_lib.c')
-rw-r--r--ssl/d1_lib.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ssl/d1_lib.c b/ssl/d1_lib.c
index 9f8b33b193..2f696c52d8 100644
--- a/ssl/d1_lib.c
+++ b/ssl/d1_lib.c
@@ -406,7 +406,8 @@ int dtls1_check_timeout_num(SSL *s)
s->d1->timeout.num_alerts++;
/* Reduce MTU after 2 unsuccessful retransmissions */
- if (s->d1->timeout.num_alerts > 2)
+ if (s->d1->timeout.num_alerts > 2
+ && !(SSL_get_options(s) & SSL_OP_NO_QUERY_MTU))
{
s->d1->mtu = BIO_ctrl(SSL_get_wbio(s), BIO_CTRL_DGRAM_GET_FALLBACK_MTU, 0, NULL);
}