X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fcoremods%2Fcore_stats.cpp;h=9fb232bc0192bb7a2e1d0210f1e580a09042df3d;hb=7b6bd133ca4472f6cb8058d5e34e3c8b2af7e99a;hp=180ece9b3b1f56ee883bc19aa42d35792524f85d;hpb=bd1471bc08be28bc2554d35fdaeb078338b14266;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/coremods/core_stats.cpp b/src/coremods/core_stats.cpp index 180ece9b3..9fb232bc0 100644 --- a/src/coremods/core_stats.cpp +++ b/src/coremods/core_stats.cpp @@ -99,6 +99,11 @@ void CommandStats::DoStats(char statschar, User* user, string_list &results) std::string ip = ls->bind_addr; if (ip.empty()) ip.assign("*"); + else if (ip.find_first_of(':') != std::string::npos) + { + ip.insert(ip.begin(), '['); + ip.insert(ip.end(), ']'); + } std::string type = ls->bind_tag->getString("type", "clients"); std::string hook = ls->bind_tag->getString("ssl", "plaintext");