summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Petersson <martin.petersson@nokia.com>2011-02-18 09:38:00 (GMT)
committerMartin Petersson <martin.petersson@nokia.com>2011-02-18 09:47:55 (GMT)
commit4df61b4bad57a08a30b8898eb73c720bc9c328a8 (patch)
tree5b8b5e8ac73dcc1a3701c9c10feea1f2ad42f506
parent59dd0bf5bf36ea0ccb9b42d5ae44f6980c396fdf (diff)
downloadQt-4df61b4bad57a08a30b8898eb73c720bc9c328a8.zip
Qt-4df61b4bad57a08a30b8898eb73c720bc9c328a8.tar.gz
Qt-4df61b4bad57a08a30b8898eb73c720bc9c328a8.tar.bz2
QAbstractSocket: Do not always change notifier on setReadBufferSize
When the connecting process is in progress we should not enable the read notifier. This will be done when we are connected. This fixes the tst_qnetworkreply proxyChange() on Windows. Reviewed-by: Markus Goetz
-rw-r--r--src/network/socket/qabstractsocket.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/network/socket/qabstractsocket.cpp b/src/network/socket/qabstractsocket.cpp
index ead9897..9c82db8 100644
--- a/src/network/socket/qabstractsocket.cpp
+++ b/src/network/socket/qabstractsocket.cpp
@@ -2624,7 +2624,7 @@ void QAbstractSocket::setReadBufferSize(qint64 size)
// ensure that the read notification is enabled if we've now got
// room in the read buffer
// but only if we're not inside canReadNotification -- that will take care on its own
- if (size == 0 || d->readBuffer.size() < size)
+ if ((size == 0 || d->readBuffer.size() < size) && d->state == Connected) // Do not change the notifier unless we are connected.
d->socketEngine->setReadNotificationEnabled(true);
}
}