kio: do not use static buffer in SocketConnectionBackend::socketReadyRead()

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2021-08-26 00:13:34 +03:00
parent 2da04652d4
commit feda883352

View file

@ -276,7 +276,7 @@ void SocketConnectionBackend::socketReadyRead()
// kDebug() << this << "Got " << socket->bytesAvailable() << " bytes"; // kDebug() << this << "Got " << socket->bytesAvailable() << " bytes";
if (len == -1) { if (len == -1) {
// We have to read the header // We have to read the header
static char buffer[HeaderSize]; char buffer[HeaderSize];
if (socket->bytesAvailable() < HeaderSize) { if (socket->bytesAvailable() < HeaderSize) {
return; // wait for more data return; // wait for more data