summaryrefslogtreecommitdiffstats
path: root/src/plugins/tls/openssl/qsslcontext_openssl.cpp
diff options
context:
space:
mode:
authorMichael Saxl <michael.saxl@troyer.it>2022-07-20 08:52:02 +0200
committerMichael Saxl <michael.saxl@troyer.it>2022-08-04 18:47:10 +0200
commite995bfc0ea783c15bb173f060099ca24f277c763 (patch)
tree316c1da8d4cd0f00c60f8074c4dcceb3c2104bf6 /src/plugins/tls/openssl/qsslcontext_openssl.cpp
parente00e215e006374a2b8e232c413de75e4d6504f5b (diff)
update function argument of SSL_CTX_set_options
openssl3 uses uint64_t for the options argument in SSL_CTX_set_options, older ones used long. sizeof(long) is not the same on any platform as sizeof(uint64_t) Fixes: QTBUG-105041 Change-Id: If148ffd883f50b58bc284c6f2609337d80fb5c58 Pick-to: 5.15 6.2 6.3 6.4 Reviewed-by: Dmitry Shachnev <mitya57@gmail.com> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Diffstat (limited to 'src/plugins/tls/openssl/qsslcontext_openssl.cpp')
-rw-r--r--src/plugins/tls/openssl/qsslcontext_openssl.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/plugins/tls/openssl/qsslcontext_openssl.cpp b/src/plugins/tls/openssl/qsslcontext_openssl.cpp
index 9e59477634..33f0d41a09 100644
--- a/src/plugins/tls/openssl/qsslcontext_openssl.cpp
+++ b/src/plugins/tls/openssl/qsslcontext_openssl.cpp
@@ -63,9 +63,9 @@ static inline QString msgErrorSettingEllipticCurves(const QString &why)
return QSslSocket::tr("Error when setting the elliptic curves (%1)").arg(why);
}
-long QSslContext::setupOpenSslOptions(QSsl::SslProtocol protocol, QSsl::SslOptions sslOptions)
+qssloptions QSslContext::setupOpenSslOptions(QSsl::SslProtocol protocol, QSsl::SslOptions sslOptions)
{
- long options;
+ qssloptions options;
switch (protocol) {
QT_WARNING_PUSH
QT_WARNING_DISABLE_DEPRECATED
@@ -476,7 +476,7 @@ QT_WARNING_POP
}
// Enable bug workarounds.
- const long options = setupOpenSslOptions(configuration.protocol(), configuration.d->sslOptions);
+ const qssloptions options = setupOpenSslOptions(configuration.protocol(), configuration.d->sslOptions);
q_SSL_CTX_set_options(sslContext->ctx, options);
// Tell OpenSSL to release memory early