1
0
mirror of https://github.com/anope/anope.git synced 2026-06-27 21:06:37 +02:00

Show a better log message when disconnecting from the uplink

This commit is contained in:
Adam
2014-03-19 02:40:48 -04:00
parent 4f412bc213
commit c1da009de3
+2 -1
View File
@@ -138,7 +138,8 @@ void UplinkSocket::OnConnect()
void UplinkSocket::OnError(const Anope::string &error)
{
Log(LOG_TERMINAL) << "Unable to connect to uplink #" << (Anope::CurrentUplink + 1) << " (" << Config->Uplinks[Anope::CurrentUplink].host << ":" << Config->Uplinks[Anope::CurrentUplink].port << ")" << (!error.empty() ? (": " + error) : "");
Anope::string what = !this->flags[SF_CONNECTED] ? "Unable to connect to" : "Lost connection from";
Log(LOG_TERMINAL) << what << " uplink #" << (Anope::CurrentUplink + 1) << " (" << Config->Uplinks[Anope::CurrentUplink].host << ":" << Config->Uplinks[Anope::CurrentUplink].port << ")" << (!error.empty() ? (": " + error) : "");
}
UplinkSocket::Message::Message() : source(Me)