Don't 'close' a socket after a TCP reply - instead just disconnect from the host after all data has been transmitted.

This commit is contained in:
Ken Moore
2016-01-05 14:17:46 -05:00
parent a5fcddcbbe
commit a1ba1044ee

View File

@@ -70,7 +70,7 @@ void WebSocket::sendReply(QString msg){
else if(TSOCKET!=0){
//TCP Socket connection
TSOCKET->write(msg.toUtf8().data());
TSOCKET->close(); //TCP/REST connections are 1 connection per message.
TSOCKET->disconnectFromHost(); //TCP/REST connections are 1 connection per message.
}
}