summaryrefslogtreecommitdiffstats
path: root/src/network/access/qnetworkaccesshttpbackend.cpp
diff options
context:
space:
mode:
authorMarkus Goetz <Markus.Goetz@nokia.com>2010-01-11 12:24:15 (GMT)
committerMarkus Goetz <Markus.Goetz@nokia.com>2010-01-11 14:27:13 (GMT)
commit36dcdcdf5b6869ded0401a879b1397ad9d20b324 (patch)
tree96d86590e989ed623f518b0648683c323ae6c002 /src/network/access/qnetworkaccesshttpbackend.cpp
parente2a94baeed03edbaeea9b4658f2a820520e1363f (diff)
downloadQt-36dcdcdf5b6869ded0401a879b1397ad9d20b324.zip
Qt-36dcdcdf5b6869ded0401a879b1397ad9d20b324.tar.gz
Qt-36dcdcdf5b6869ded0401a879b1397ad9d20b324.tar.bz2
QNAM HTTP: Fix readBuffer maximum size.
QHttpNetworkReply has now a throttled mode. If this is activated, it will only read HTTP body when its internal buffer is empty. This means that QNetworkReply.setReadBufferSize() can finally be used for bandwidth limiting. Thanks to David Faure for helping out. Reviewed-By: Peter Hartmann
Diffstat (limited to 'src/network/access/qnetworkaccesshttpbackend.cpp')
-rw-r--r--src/network/access/qnetworkaccesshttpbackend.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/network/access/qnetworkaccesshttpbackend.cpp b/src/network/access/qnetworkaccesshttpbackend.cpp
index dacb2bb..a639e0d 100644
--- a/src/network/access/qnetworkaccesshttpbackend.cpp
+++ b/src/network/access/qnetworkaccesshttpbackend.cpp
@@ -657,6 +657,12 @@ void QNetworkAccessHttpBackend::downstreamReadyWrite()
replyFinished();
}
+void QNetworkAccessHttpBackend::setDownstreamLimited(bool b)
+{
+ if (httpReply)
+ httpReply->setDownstreamLimited(b);
+}
+
void QNetworkAccessHttpBackend::replyReadyRead()
{
readFromHttp();