diff options
author | Florent Le Coz <louiz@louiz.org> | 2015-04-21 15:35:10 +0200 |
---|---|---|
committer | Florent Le Coz <louiz@louiz.org> | 2015-04-21 15:38:22 +0200 |
commit | a8225dc54c019788722bda3bda8d55151c1ccdef (patch) | |
tree | 6ff229bd0afd788a4a8300a237f9fa2eca9bea52 | |
parent | d79850f984cb5aa9579ebc5f5e53696fc7872eb8 (diff) | |
download | biboumi-a8225dc54c019788722bda3bda8d55151c1ccdef.tar.gz biboumi-a8225dc54c019788722bda3bda8d55151c1ccdef.tar.bz2 biboumi-a8225dc54c019788722bda3bda8d55151c1ccdef.tar.xz biboumi-a8225dc54c019788722bda3bda8d55151c1ccdef.zip |
Properly check for connecting or connected status before reconnecting
Note, in our context, is_connecting() includes the resolving part as well as
the actual connection (if we are using c-ares)
fix #3048
m--------- | louloulibs | 0 | ||||
-rw-r--r-- | src/irc/irc_client.cpp | 4 |
2 files changed, 2 insertions, 2 deletions
diff --git a/louloulibs b/louloulibs -Subproject b53ae922f48f1465a7fa61136f65ec39e38a452 +Subproject 6c812cd86e31569db61cac4e30f77e296d20719 diff --git a/src/irc/irc_client.cpp b/src/irc/irc_client.cpp index 694baf8..b0ce93a 100644 --- a/src/irc/irc_client.cpp +++ b/src/irc/irc_client.cpp @@ -55,8 +55,8 @@ IrcClient::~IrcClient() void IrcClient::start() { - if (this->connected || this->connecting) - return ; + if (this->is_connecting() || this->is_connected()) + return; std::string port; bool tls; std::tie(port, tls) = this->ports_to_try.top(); |