Hi

a server sends 162076 bytes to the client. The client reads the QTcpSocket and gets only 16384 bytes back and the program crashes.

What's the best way to read all data?
Qt Code:
  1. QByteArray byteblock = tcpsocket->read();
  2. QDataStream stream(&byteblock, QIODevice::ReadOnly);
  3. QString str;
  4. stream >> str;
  5. qDebug() << "received:" << str;
To copy to clipboard, switch view to plain text mode 
Debug output is: received ""

thank u!