QLocalSocket: remove double buffer on qlocalsocket_unix
The QLocalSocket is using a QLocalUnixSocket which is a QTcpSocket that has buffering enabled. Because QLocalSocket is a QIODevice it also has its own read buffer. By opening the QIODevice Unbuffered we only use the buffer in the QLocalUnixSocket. Change-Id: I4b9091522f73b0831b20efb4a2a00c2603fc748b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
This commit is contained in:
parent
68f44a7f98
commit
f956f9a836
@ -338,7 +338,7 @@ void QLocalSocketPrivate::_q_connectToSocket()
|
||||
fullServerName = connectingPathName;
|
||||
if (unixSocket.setSocketDescriptor(connectingSocket,
|
||||
QAbstractSocket::ConnectedState, connectingOpenMode)) {
|
||||
q->QIODevice::open(connectingOpenMode);
|
||||
q->QIODevice::open(connectingOpenMode | QIODevice::Unbuffered);
|
||||
q->emit connected();
|
||||
} else {
|
||||
QString function = QLatin1String("QLocalSocket::connectToServer");
|
||||
|
Loading…
Reference in New Issue
Block a user