QHttpNetworkConnectionPrivate: NSDMI
Initialize the hardcoded things inside the class. Task-number: QTBUG-102855 Change-Id: I06da0a615ec066e63d9cd0359313e8e8f588718e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>bb10
parent
28bff27b85
commit
c9e6cdc19e
|
|
@ -52,14 +52,12 @@ static int getPreferredActiveChannelCount(QHttpNetworkConnection::ConnectionType
|
|||
QHttpNetworkConnectionPrivate::QHttpNetworkConnectionPrivate(quint16 connectionCount, const QString &hostName,
|
||||
quint16 port, bool encrypt,
|
||||
QHttpNetworkConnection::ConnectionType type)
|
||||
: state(RunningState), networkLayerState(Unknown),
|
||||
hostName(hostName), port(port), encrypt(encrypt), delayIpv4(true),
|
||||
: hostName(hostName), port(port), encrypt(encrypt),
|
||||
activeChannelCount(getPreferredActiveChannelCount(type, connectionCount)),
|
||||
channelCount(connectionCount), channels(new QHttpNetworkConnectionChannel[channelCount])
|
||||
#ifndef QT_NO_NETWORKPROXY
|
||||
, networkProxy(QNetworkProxy::NoProxy)
|
||||
#endif
|
||||
, preConnectRequests(0)
|
||||
, connectionType(type)
|
||||
{
|
||||
// We allocate all 6 channels even if it's an HTTP/2-enabled
|
||||
|
|
|
|||
|
|
@ -160,8 +160,8 @@ public:
|
|||
|
||||
void pauseConnection();
|
||||
void resumeConnection();
|
||||
ConnectionState state;
|
||||
NetworkLayerPreferenceState networkLayerState;
|
||||
ConnectionState state = RunningState;
|
||||
NetworkLayerPreferenceState networkLayerState = Unknown;
|
||||
|
||||
enum { ChunkSize = 4096 };
|
||||
|
||||
|
|
@ -204,7 +204,7 @@ public:
|
|||
QString hostName;
|
||||
quint16 port;
|
||||
bool encrypt;
|
||||
bool delayIpv4;
|
||||
bool delayIpv4 = true;
|
||||
|
||||
// Number of channels we are trying to use at the moment:
|
||||
int activeChannelCount;
|
||||
|
|
@ -237,7 +237,7 @@ public:
|
|||
QList<HttpMessagePair> highPriorityQueue;
|
||||
QList<HttpMessagePair> lowPriorityQueue;
|
||||
|
||||
int preConnectRequests;
|
||||
int preConnectRequests = 0;
|
||||
|
||||
QHttpNetworkConnection::ConnectionType connectionType;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue