remove useless code when reading response
This commit is contained in:
@@ -55,7 +55,7 @@ void McClient::readBytesExactFromSocket(QByteArray &resp, int bytesToRead) {
|
||||
throw Exception("Read timeout or error");
|
||||
}
|
||||
|
||||
QByteArray chunk = socket.read(qMin(bytesToRead, socket.bytesAvailable()));
|
||||
QByteArray chunk = socket.read(bytesToRead);
|
||||
resp.append(chunk);
|
||||
bytesToRead -= chunk.size();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user