diff options
author | Matt Caswell <matt@openssl.org> | 2014-12-01 11:13:15 +0000 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2014-12-03 09:32:48 +0000 |
commit | 8aaeec9f9a46b4f79d70e30ff5bb189f0283797d (patch) | |
tree | 858ee88ef2f5ee867190487d6f7fc0115845408a /ssl/d1_both.c | |
parent | 8454d3f924bb642665679353dee983f7d325f714 (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_both.c')
-rw-r--r-- | ssl/d1_both.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/ssl/d1_both.c b/ssl/d1_both.c index 99a031c0af..4e68a2907b 100644 --- a/ssl/d1_both.c +++ b/ssl/d1_both.c @@ -350,10 +350,17 @@ int dtls1_do_write(SSL *s, int type) */ if ( BIO_ctrl(SSL_get_wbio(s), BIO_CTRL_DGRAM_MTU_EXCEEDED, 0, NULL) > 0 ) - s->d1->mtu = BIO_ctrl(SSL_get_wbio(s), - BIO_CTRL_DGRAM_QUERY_MTU, 0, NULL); + { + if(!(SSL_get_options(s) & SSL_OP_NO_QUERY_MTU)) + s->d1->mtu = BIO_ctrl(SSL_get_wbio(s), + BIO_CTRL_DGRAM_QUERY_MTU, 0, NULL); + else + return -1; + } else + { return(-1); + } } else { |