> Hi,
>
> Does anyone use QNetworkAccessManager and QNetworkReply? I've some odd
> behaviour with them in that the uploadProgress() event is fired and
> has no real baring on the actual progress of the upload.
That's a bug and has been fixed.
I don't remember if we could fix it for the 4.5.x series, though. I'm certain
it's fixed for the upcoming 4.6.0.
What happens is that the QNetworkReply class emits the signal when it writes
to its backend (the private QHttpNetworkConnection class). However, since
QTcpSocket's outgoing buffer is not bounded, QHttpNetworkConnection ends up
transferring all bytes from your source data directly into the socket buffer.
So we buffer everything in memory and then send as fast as the kernel socket
can send.
The fix was to control the buffer size and stop reading from the user once we
reach a certain threshold.
--
Thiago Macieira - thiago.macieira (AT) nokia.com
Senior Product Manager - Nokia, Qt Development Frameworks
Sandakerveien 116, NO-0402 Oslo, Norway
Bookmarks