summaryrefslogtreecommitdiff
path: root/src/gui/serverdialog.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-04-21 18:57:48 +0300
committerAndrei Karas <akaras@inbox.ru>2013-04-21 18:57:48 +0300
commit35cfd460655878c9a615abc8ea1cb2f7577a7f3b (patch)
tree2b4cb899f7f442912f89de30f4a5ab0add0727ce /src/gui/serverdialog.cpp
parentcfe4c893ba4ba30379919636d3c508ebf1594e23 (diff)
downloadplus-35cfd460655878c9a615abc8ea1cb2f7577a7f3b.tar.gz
plus-35cfd460655878c9a615abc8ea1cb2f7577a7f3b.tar.bz2
plus-35cfd460655878c9a615abc8ea1cb2f7577a7f3b.tar.xz
plus-35cfd460655878c9a615abc8ea1cb2f7577a7f3b.zip
some other fixes from cpplint.
Diffstat (limited to 'src/gui/serverdialog.cpp')
-rw-r--r--src/gui/serverdialog.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/serverdialog.cpp b/src/gui/serverdialog.cpp
index ee879f2a8..56ce6528a 100644
--- a/src/gui/serverdialog.cpp
+++ b/src/gui/serverdialog.cpp
@@ -86,7 +86,7 @@ static std::string serverTypeToString(const ServerInfo::Type type)
}
}
-static unsigned short defaultPortForServerType(const ServerInfo::Type type)
+static uint16_t defaultPortForServerType(const ServerInfo::Type type)
{
switch (type)
{
@@ -616,7 +616,7 @@ void ServerDialog::loadServers(const bool addNew)
if (xmlNameEqual(subNode, "connection"))
{
server.hostname = XML::getProperty(subNode, "hostname", "");
- server.port = static_cast<short unsigned>(
+ server.port = static_cast<uint16_t>(
XML::getProperty(subNode, "port", 0));
if (server.port == 0)
@@ -685,7 +685,7 @@ void ServerDialog::loadCustomServers()
server.type = ServerInfo::parseType(config.getValue(typeKey, ""));
const int defaultPort = defaultPortForServerType(server.type);
- server.port = static_cast<unsigned short>(
+ server.port = static_cast<uint16_t>(
config.getValue(portKey, defaultPort));
// skip invalid server