diff options
-rw-r--r-- | src/users.cpp | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/src/users.cpp b/src/users.cpp index 41caa5c5a..5ddd98def 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -648,14 +648,7 @@ void LocalUser::OverruleNick() int LocalUser::GetServerPort() { - switch (this->server_sa.sa.sa_family) - { - case AF_INET6: - return htons(this->server_sa.in6.sin6_port); - case AF_INET: - return htons(this->server_sa.in4.sin_port); - } - return 0; + return this->server_sa.port(); } const std::string& User::GetIPString() |