You are correct... The first line was in the "in" buffer.... while i was only printing the "response".
This seems to work fine...
Thanks for the pointer.
void Rsh::receiveMessage() {
if( !tcpSocket->canReadLine() )
{
return;
}
while( tcpSocket->canReadLine() ){
responseLine = in.readAll();
response.append(responseLine);
}
ui.ResultsTextEdit->append(response);
}
void Rsh::receiveMessage() {
QString responseLine;
QString response;
QTextStream in(tcpSocket);
if( !tcpSocket->canReadLine() )
{
return;
}
while( tcpSocket->canReadLine() ){
responseLine = in.readAll();
response.append(responseLine);
}
ui.ResultsTextEdit->append(response);
}
To copy to clipboard, switch view to plain text mode
Bookmarks