diff options
author | Thanos Doukoudakis <thanos.doukoudakis@isode.com> | 2018-01-08 18:08:01 (GMT) |
---|---|---|
committer | Thanos Doukoudakis <thanos.doukoudakis@isode.com> | 2018-01-09 10:33:18 (GMT) |
commit | f978788a2c8844a24d2481c4d70b1bb5a152d1fb (patch) | |
tree | 244d9eda408fd2f49cdf5a88ebf08880122bca01 /Swiften/Network | |
parent | 842a9651b9ead023bc079decfe3bce9f9257bee7 (diff) | |
download | swift-f978788a2c8844a24d2481c4d70b1bb5a152d1fb.zip swift-f978788a2c8844a24d2481c4d70b1bb5a152d1fb.tar.bz2 |
Add an log assertion to Connectors
This will check that the connection object is valid when a connector
timeouts, and if not log it.
Test-Information:
None
Change-Id: I0af3e88fe1f527c25c4bb6c886668d19167b489b
Diffstat (limited to 'Swiften/Network')
-rw-r--r-- | Swiften/Network/Connector.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Swiften/Network/Connector.cpp b/Swiften/Network/Connector.cpp index 457d8a9..e86b327 100644 --- a/Swiften/Network/Connector.cpp +++ b/Swiften/Network/Connector.cpp @@ -189,6 +189,7 @@ void Connector::finish(std::shared_ptr<Connection> connection) { void Connector::handleTimeout() { SWIFT_LOG(debug) << "Timeout" << std::endl; + SWIFT_LOG_ASSERT(currentConnection, error) << "Connection not valid but triggered a timeout" <<std::endl; handleConnectionConnectFinished(true); } |