summaryrefslogtreecommitdiffstats
path: root/src/network
diff options
context:
space:
mode:
authorTimur Pocheptsov <timur.pocheptsov@qt.io>2020-05-08 12:52:25 +0200
committerTimur Pocheptsov <timur.pocheptsov@qt.io>2020-05-08 18:11:03 +0200
commit920487bf6b4d06ce9fef82e99e262ee0dd7d2ea3 (patch)
tree46d5e10bdffc3540ce6f4737c5711b2168121483 /src/network
parentf579be96f7ad0362220f710a03a390d1c1139c52 (diff)
QSslSocket::setSslSonfiguration - set d.configuration properly
We end up with an absurd situation: QSslConfiguration conf; //we set CA certs so that on demand loading is disabled: conf.setCaCertificates({...}); QSslSocket s; s.setSslConfiguration(conf); Q_ASSERT(conf == s.sslConfiguration); // this assert fails. Pick-to: 5.15 Change-Id: I272bed145434082acc6ead95fe3640d222b21131 Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io>
Diffstat (limited to 'src/network')
-rw-r--r--src/network/ssl/qsslsocket.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/network/ssl/qsslsocket.cpp b/src/network/ssl/qsslsocket.cpp
index 5313e97430..5252f3348b 100644
--- a/src/network/ssl/qsslsocket.cpp
+++ b/src/network/ssl/qsslsocket.cpp
@@ -1111,8 +1111,10 @@ void QSslSocket::setSslConfiguration(const QSslConfiguration &configuration)
// if the CA certificates were set explicitly (either via
// QSslConfiguration::setCaCertificates() or QSslSocket::setCaCertificates(),
// we cannot load the certificates on demand
- if (!configuration.d->allowRootCertOnDemandLoading)
+ if (!configuration.d->allowRootCertOnDemandLoading) {
d->allowRootCertOnDemandLoading = false;
+ d->configuration.allowRootCertOnDemandLoading = false;
+ }
}
/*!