Fix a segmentation fault when connecting to a server without a port
fix #3260
This commit is contained in:
@@ -18,6 +18,12 @@ Version 5.0
|
|||||||
- Botan’s TLS policies can be customized by the administrator, for each
|
- Botan’s TLS policies can be customized by the administrator, for each
|
||||||
IRC server, with simple text files.
|
IRC server, with simple text files.
|
||||||
|
|
||||||
|
Version 4.3 - 2017-05-02
|
||||||
|
========================
|
||||||
|
|
||||||
|
- Fix a segmentation fault that occured when trying to connect to an IRC
|
||||||
|
server without any port configured.
|
||||||
|
|
||||||
Version 4.2 - 2017-04-26
|
Version 4.2 - 2017-04-26
|
||||||
========================
|
========================
|
||||||
|
|
||||||
|
|||||||
@@ -62,6 +62,10 @@ make check %{?_smp_mflags}
|
|||||||
* ${RPM_DATE} Le Coz Florent <louiz@louiz.org> - ${RPM_VERSION}-1
|
* ${RPM_DATE} Le Coz Florent <louiz@louiz.org> - ${RPM_VERSION}-1
|
||||||
- Build latest git revision
|
- Build latest git revision
|
||||||
|
|
||||||
|
* Wed May 2 2017 Le Coz Florent <louiz@louiz.org> - 4.3-1
|
||||||
|
- Fix a segmentation fault that occured when trying to connect
|
||||||
|
to an IRC server without any port configured.
|
||||||
|
|
||||||
* Wed Apr 26 2017 Le Coz Florent <louiz@louiz.org> - 4.2-1
|
* Wed Apr 26 2017 Le Coz Florent <louiz@louiz.org> - 4.2-1
|
||||||
- Fix a build issue when LiteSQL is absent from the system
|
- Fix a build issue when LiteSQL is absent from the system
|
||||||
|
|
||||||
|
|||||||
@@ -183,6 +183,11 @@ void IrcClient::start()
|
|||||||
{
|
{
|
||||||
if (this->is_connecting() || this->is_connected())
|
if (this->is_connecting() || this->is_connected())
|
||||||
return;
|
return;
|
||||||
|
if (this->ports_to_try.empty())
|
||||||
|
{
|
||||||
|
this->bridge.send_xmpp_message(this->hostname, "", "Can not connect to IRC server: no port specified.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
std::string port;
|
std::string port;
|
||||||
bool tls;
|
bool tls;
|
||||||
std::tie(port, tls) = this->ports_to_try.top();
|
std::tie(port, tls) = this->ports_to_try.top();
|
||||||
|
|||||||
Reference in New Issue
Block a user