diff options
| author | Marco Bubke <marco.bubke@theqtcompany.com> | 2015-06-01 13:17:13 +0200 |
|---|---|---|
| committer | Nikolai Kosjar <nikolai.kosjar@theqtcompany.com> | 2015-06-01 11:54:28 +0000 |
| commit | 696b5a014232b13e7cf7165028e976dda1baaa6e (patch) | |
| tree | 9111f58a794ffba1307aad06f757f33f66ca154d | |
| parent | a946548ca49d575f311d93cad6b7f5b9acb62788 (diff) | |
| download | qt-creator-696b5a014232b13e7cf7165028e976dda1baaa6e.tar.gz | |
Print connection client local socket errors
Change-Id: Ie06148a040d52f74900c7881402c1a39afa75c6a
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
| -rw-r--r-- | src/libs/codemodelbackendipc/connectionclient.cpp | 9 | ||||
| -rw-r--r-- | src/libs/codemodelbackendipc/connectionclient.h | 1 |
2 files changed, 10 insertions, 0 deletions
diff --git a/src/libs/codemodelbackendipc/connectionclient.cpp b/src/libs/codemodelbackendipc/connectionclient.cpp index 73d86b6de1..251cbc7a6c 100644 --- a/src/libs/codemodelbackendipc/connectionclient.cpp +++ b/src/libs/codemodelbackendipc/connectionclient.cpp @@ -58,6 +58,10 @@ ConnectionClient::ConnectionClient(IpcClientInterface *client) processAliveTimer.setInterval(10000); connect(&processAliveTimer, &QTimer::timeout, this, &ConnectionClient::restartProcess); + connect(&localSocket, + static_cast<void (QLocalSocket::*)(QLocalSocket::LocalSocketError)>(&QLocalSocket::error), + this, + &ConnectionClient::printLocalSocketError); } ConnectionClient::~ConnectionClient() @@ -168,6 +172,11 @@ void ConnectionClient::killProcess() } } +void ConnectionClient::printLocalSocketError(QLocalSocket::LocalSocketError /*socketError*/) +{ + qWarning() << "ClangCodeModel ConnectionClient LocalSocket Error:" << localSocket.errorString(); +} + void ConnectionClient::finishProcess() { processAliveTimer.stop(); diff --git a/src/libs/codemodelbackendipc/connectionclient.h b/src/libs/codemodelbackendipc/connectionclient.h index cc3632bd64..ba6031b35a 100644 --- a/src/libs/codemodelbackendipc/connectionclient.h +++ b/src/libs/codemodelbackendipc/connectionclient.h @@ -87,6 +87,7 @@ private: void endProcess(); void terminateProcess(); void killProcess(); + void printLocalSocketError(QLocalSocket::LocalSocketError socketError); QProcess *process() const; void connectProcessFinished() const; |
