From a8225dc54c019788722bda3bda8d55151c1ccdef Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Tue, 21 Apr 2015 15:35:10 +0200 Subject: 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 --- louloulibs | 2 +- src/irc/irc_client.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/louloulibs b/louloulibs index b53ae92..6c812cd 160000 --- a/louloulibs +++ b/louloulibs @@ -1 +1 @@ -Subproject commit b53ae922f48f1465a7fa61136f65ec39e38a452e +Subproject commit 6c812cd86e31569db61cac4e30f77e296d207191 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(); -- cgit v1.2.3