PDA

View Full Version : (SOLVED)QNetworkAccessManager and Transfer-Encoding: chunked - dont retrieve all data



Talei
21st July 2010, 21:55
Hello,
I have a piece of code like this:

netMenag = new QNetworkAccessManager( this );
connect( netMenag, SIGNAL( finished(QNetworkReply*) ), this, SLOT( readDataGET(QNetworkReply*) ), Qt::QueuedConnection );
netMenag->get( header );
to retrieve WEB page send from the server. The problem with that is that in slot readDataGET(QNetworkReply*), QNetworkReply contains only first packet of the chunked transmission.
Same hapens when I use QTcpSocket. I can see with qDebug() << socket->readAll(); all the packets but for some unknown to me reasons when I do QByteArray HTTP.append( socket->readAll() ); data don't contains full reply from server.

Any thoughts about retrieving data with HTTP Transfer-Encoding: chunked.?

Regards

EDIT:
Solved. It seams that qDebug() don't show more then ~33KB of the data, so my output was truncated.