summaryrefslogtreecommitdiffstats
path: root/src/network
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2016-06-22 22:28:12 +0200
committerLiang Qi <liang.qi@qt.io>2016-06-22 20:32:31 +0000
commitf4f7ae013da9bb253e367c879e23abcd55515f82 (patch)
tree9d77ac68314a9ba2c59d381028c73cdbfb0150cb /src/network
parentbff15c547e71e79738dfc9de89c4ef05947c0953 (diff)
Fix inconsistency between the #if guards in SSL PSK code - Part 2
The declaration and definition of the forwarding functions for PSK differed which leads to link errors with some versions of openssl. Change-Id: Ic62d87dbd33a77f3c114f0a597a6c0858b22174a Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: André Klitzing <aklitzing@gmail.com>
Diffstat (limited to 'src/network')
-rw-r--r--src/network/ssl/qsslcontext_openssl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/network/ssl/qsslcontext_openssl.cpp b/src/network/ssl/qsslcontext_openssl.cpp
index 5a80d08e24..dec8e12abb 100644
--- a/src/network/ssl/qsslcontext_openssl.cpp
+++ b/src/network/ssl/qsslcontext_openssl.cpp
@@ -344,10 +344,10 @@ init_context:
}
#endif // OPENSSL_NO_EC
-#ifndef OPENSSL_NO_PSK
+#if OPENSSL_VERSION_NUMBER >= 0x10001000L && !defined(OPENSSL_NO_PSK)
if (!client)
q_SSL_CTX_use_psk_identity_hint(sslContext->ctx, sslContext->sslConfiguration.preSharedKeyIdentityHint().constData());
-#endif // OPENSSL_NO_PSK
+#endif // OPENSSL_VERSION_NUMBER >= 0x10001000L && !defined(OPENSSL_NO_PSK)
const QVector<QSslEllipticCurve> qcurves = sslContext->sslConfiguration.ellipticCurves();
if (!qcurves.isEmpty()) {