diff options
author | Ulf Hermann <[email protected]> | 2014-05-05 18:01:02 +0200 |
---|---|---|
committer | Ulf Hermann <[email protected]> | 2014-05-08 13:40:31 +0200 |
commit | ba5c136a6da15f81d35df73557ffd6ad5ef3eed0 (patch) | |
tree | 731392584d4239a7ee18e869f89956ef0811622c /src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp | |
parent | 10252364bb0cab8dda311b9c24867d353df3ea95 (diff) |
QmlDebugClient: Check for gotHello to determine if connection is open
The isConnected() method was misleading as it only checked for the
network socket to be connected. Sending data before the hello message
arrives is a pretty stupid idea and the debug clients need a way to
detect that. The new isOpen method stresses that it's about the
logical protocol, not the network socket.
Change-Id: I84f093d91d7a21d20a8f3d14730c9f189ec35bde
Reviewed-by: Kai Koehne <[email protected]>
Diffstat (limited to 'src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp')
-rw-r--r-- | src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp b/src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp index 5501d505156..906573dde1a 100644 --- a/src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp +++ b/src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp @@ -243,7 +243,7 @@ void QmlProfilerClientManager::connectToClient() bool QmlProfilerClientManager::isConnected() const { - return d->connection && d->connection->isConnected(); + return d->connection && d->connection->isOpen(); } void QmlProfilerClientManager::disconnectClient() @@ -260,7 +260,7 @@ void QmlProfilerClientManager::tryToConnect() { ++d->connectionAttempts; - if (d->connection && d->connection->isConnected()) { + if (d->connection && d->connection->isOpen()) { d->connectionTimer.stop(); d->connectionAttempts = 0; } else if (d->connectionAttempts == 50) { |