From c001a1597329d6ec55f1385c8b364d87963df52a Mon Sep 17 00:00:00 2001 From: Andy Green Date: Fri, 6 Jan 2017 09:49:28 +0800 Subject: [PATCH] openssl: deal with missing OPENSSL_NO_TLSEXT on ancient versions --- lib/private-libwebsockets.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/lib/private-libwebsockets.h b/lib/private-libwebsockets.h index 98f3c6846..cd36c3578 100644 --- a/lib/private-libwebsockets.h +++ b/lib/private-libwebsockets.h @@ -282,6 +282,15 @@ lws_plat_get_peer_simple(struct lws *wsi, char *name, int namelen); #include #endif #include + +#if (OPENSSL_VERSION_NUMBER < 0x0009080afL) +/* later openssl defines this to negate the presence of tlsext... but it was only + * introduced at 0.9.8j. Earlier versions don't know it exists so don't + * define it... making it look like the feature exists... + */ +#define OPENSSL_NO_TLSEXT +#endif + #endif /* not USE_MBEDTLS */ #endif /* not USE_POLARSSL */ #endif /* not USE_WOLFSSL */