summaryrefslogtreecommitdiffstats
path: root/src/network/access/qhttpthreaddelegate_p.h
diff options
context:
space:
mode:
authorTimur Pocheptsov <timur.pocheptsov@qt.io>2017-03-27 15:55:34 +0200
committerTimur Pocheptsov <timur.pocheptsov@qt.io>2017-04-26 19:00:47 +0000
commit70d8460fc20dab2e1408b8d27ef5fe7a80ba9dc6 (patch)
tree2b83b2bc283237d6c224c58ad4b131a45dc0b0d3 /src/network/access/qhttpthreaddelegate_p.h
parent4ba740b3bac6e1824c18614f579d106eee930d42 (diff)
QNAM: delay SSL initialization
It's really unfortunate that even a plain 'http' request results in (Open)SSL initialization; this is apparently done by QSslConfiguration's default constructor and we have several classes including QSslConfiguration as a data-member. There are different problems reported because of this, from crashes (a broken OpenSSL on Windows) to long initialization times, which is not acceptable if no 'https' request was actually executed. This patch-set is replacing data-members of type QSslConfiguration with smart-pointers and delays (Open)SSL initialization. Task-number: QTBUG-59750 Change-Id: Id1d375e689dbd2d134abbb0572a9e804d595110e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Diffstat (limited to 'src/network/access/qhttpthreaddelegate_p.h')
-rw-r--r--src/network/access/qhttpthreaddelegate_p.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/network/access/qhttpthreaddelegate_p.h b/src/network/access/qhttpthreaddelegate_p.h
index 6d1ea11f29..2f6954aa3b 100644
--- a/src/network/access/qhttpthreaddelegate_p.h
+++ b/src/network/access/qhttpthreaddelegate_p.h
@@ -63,7 +63,7 @@
#include "qhttpnetworkrequest_p.h"
#include "qhttpnetworkconnection_p.h"
#include <QSharedPointer>
-#include "qsslconfiguration.h"
+#include <QScopedPointer>
#include "private/qnoncontiguousbytedevice_p.h"
#include "qnetworkaccessauthenticationmanager_p.h"
@@ -88,7 +88,7 @@ public:
// incoming
bool ssl;
#ifndef QT_NO_SSL
- QSslConfiguration incomingSslConfiguration;
+ QScopedPointer<QSslConfiguration> incomingSslConfiguration;
#endif
QHttpNetworkRequest httpRequest;
qint64 downloadBufferMaximumSize;