mirror of
https://github.com/libp2p/go-openssl.git
synced 2025-01-15 02:40:09 +08:00
MacOSX does not have the TLSv1_X_method() functions
The header does define TLS1_X_VERSION, but the version-specific functions are not available.
This commit is contained in:
parent
0e53dd5595
commit
75f8149306
4
ctx.go
4
ctx.go
@ -63,7 +63,7 @@ static long SSL_CTX_set_tmp_ecdh_not_a_macro(SSL_CTX* ctx, EC_KEY *key) {
|
||||
#endif
|
||||
|
||||
static const SSL_METHOD *OUR_TLSv1_1_method() {
|
||||
#ifdef TLS1_1_VERSION
|
||||
#if defined(TLS1_1_VERSION) && !defined(OPENSSL_SYSNAME_MACOSX)
|
||||
return TLSv1_1_method();
|
||||
#else
|
||||
return NULL;
|
||||
@ -71,7 +71,7 @@ static const SSL_METHOD *OUR_TLSv1_1_method() {
|
||||
}
|
||||
|
||||
static const SSL_METHOD *OUR_TLSv1_2_method() {
|
||||
#ifdef TLS1_2_VERSION
|
||||
#if defined(TLS1_2_VERSION) && !defined(OPENSSL_SYSNAME_MACOSX)
|
||||
return TLSv1_2_method();
|
||||
#else
|
||||
return NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user