Fix no-dgram.
authorBen Laurie <ben@links.org>
Wed, 16 Dec 2015 13:25:07 +0000 (13:25 +0000)
committerBen Laurie <ben@links.org>
Wed, 16 Dec 2015 21:31:56 +0000 (21:31 +0000)
Reviewed-by: Tim Hudson <tjh@openssl.org>
Configure
apps/s_server.c

index cfb11ac3da005544572a420431a40d5ae21cda09..592bd771c235cff94f0dad53d3bb670fd6587b86 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -1197,6 +1197,10 @@ if (defined($disabled{"md5"}) || defined($disabled{"sha"})
        $disabled{"tls1"} = "forced";
        }
 
+if (defined($disabled{"dgram"}))
+       {
+        $disabled{"dtls"} = "forced";
+        }
 
 if (defined($disabled{"ec"}) || defined($disabled{"dsa"})
     || defined($disabled{"dh"}) || defined($disabled{"stdio"}))
index 84a640ef1a4f187f503c39dbc15f99e9b71bb46d..de9644522e0256fc61b666685cc2027ca2b80d11 100644 (file)
@@ -257,9 +257,9 @@ static char *engine_id = NULL;
 #endif
 static const char *session_id_prefix = NULL;
 
+#ifndef OPENSSL_NO_DTLS
 static int enable_timeouts = 0;
 static long socket_mtu;
-#ifndef OPENSSL_NO_DTLS
 static int cert_chain = 0;
 #endif
 static int dtlslisten = 0;
@@ -2028,7 +2028,7 @@ static int sv_body(char *hostname, int s, int stype, unsigned char *context)
         ret = -1;
         goto err;
     }
-
+#ifndef OPENSSL_NO_DTLS
     if (stype == SOCK_DGRAM) {
 
         sbio = BIO_new_dgram(s, BIO_NOCLOSE);
@@ -2065,6 +2065,7 @@ static int sv_body(char *hostname, int s, int stype, unsigned char *context)
         /* turn on cookie exchange */
         SSL_set_options(con, SSL_OP_COOKIE_EXCHANGE);
     } else
+#endif
         sbio = BIO_new_socket(s, BIO_NOCLOSE);
 
     if (s_nbio_test) {