diff options
-rw-r--r-- | src/coremods/core_stats.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
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"); |