Build fixes for MacOS
authorDirk Hohndel <dirk.hohndel@intel.com>
Wed, 15 Oct 2008 11:30:54 +0000 (12:30 +0100)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Wed, 15 Oct 2008 11:30:54 +0000 (12:30 +0100)
dtls.c

diff --git a/dtls.c b/dtls.c
index f291e1b..7fad206 100644 (file)
--- a/dtls.c
+++ b/dtls.c
@@ -28,6 +28,7 @@
 #include <unistd.h>
 #include <openssl/err.h>
 #include <fcntl.h>
+#include <string.h>
 
 #include "openconnect.h"
 
@@ -175,9 +176,11 @@ int connect_dtls_socket(struct openconnect_info *vpninfo)
        dtls_bio = BIO_new_socket(dtls_fd, BIO_NOCLOSE);
        SSL_set_bio(dtls_ssl, dtls_bio, dtls_bio);
 
+#ifndef __APPLE__
        /* XXX Cargo cult programming. Other DTLS code does this, and it might
           avoid http://rt.openssl.org/Ticket/Display.html?id=1703 */
         BIO_ctrl(dtls_bio, BIO_CTRL_DGRAM_MTU_DISCOVER, 0, NULL);
+#endif
 
 #ifndef SSL_OP_CISCO_ANYCONNECT
 #define SSL_OP_CISCO_ANYCONNECT 0x8000