# diff -pU5 hexchat-2.12.4/src/common/ssl.c.old hexchat-2.12.4/src/common/ssl.c --- hexchat-2.12.4/src/common/ssl.c +++ hexchat-2.12.4/src/common/ssl.c @@ -174,11 +174,11 @@ _SSL_get_cert_info (struct cert_info *ce key = X509_get_X509_PUBKEY(peer_cert); if (!X509_PUBKEY_get0_param(NULL, NULL, 0, &algor, key)) return 1; alg = OBJ_obj2nid (algor->algorithm); -#if OPENSSL_VERSION_NUMBER < 0x10100000L +#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined LIBRESSL_VERSION_NUMBER sign_alg = OBJ_obj2nid (peer_cert->sig_alg->algorithm); #else sign_alg = X509_get_signature_nid (peer_cert); #endif ASN1_TIME_snprintf (notBefore, sizeof (notBefore), @@ -304,11 +304,11 @@ _SSL_socket (SSL_CTX *ctx, int sd) /* FATAL */ __SSL_critical_error ("SSL_new"); SSL_set_fd (ssl, sd); -#if OPENSSL_VERSION_NUMBER < 0x10100000L +#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined LIBRESSL_VERSION_NUMBER method = ctx->method; #else method = SSL_CTX_get_ssl_method (ctx); #endif if (method == SSLv23_client_method())