aboutsummaryrefslogtreecommitdiffstats
path: root/src/configreader.cpp
diff options
context:
space:
mode:
authorGravatar Sadie Powell2020-12-21 16:40:32 +0000
committerGravatar Sadie Powell2020-12-21 16:40:52 +0000
commita63b6e16df8c2764d3d054c125239d129582d9dc (patch)
treef31ef63e126c677bf178de90775f111b29b70071 /src/configreader.cpp
parentUse unicode box drawing characters in the /MAP output. (diff)
parentReplace the SERVER stub command with something actually useful. (diff)
Merge branch 'insp3' into master.
Diffstat (limited to 'src/configreader.cpp')
-rw-r--r--src/configreader.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/configreader.cpp b/src/configreader.cpp
index cefdab358..f127c41fb 100644
--- a/src/configreader.cpp
+++ b/src/configreader.cpp
@@ -315,7 +315,7 @@ void ServerConfig::CrossCheckConnectBlocks(ServerConfig* current)
}
}
-static std::string GetServerName()
+static std::string GetServerHost()
{
#ifndef _WIN32
char hostname[256];
@@ -339,7 +339,7 @@ void ServerConfig::Fill()
auto server = ConfValue("server");
if (sid.empty())
{
- ServerName = server->getString("name", GetServerName(), InspIRCd::IsHost);
+ ServerName = server->getString("name", GetServerHost(), InspIRCd::IsHost);
sid = server->getString("id");
if (!sid.empty() && !InspIRCd::IsSID(sid))
@@ -486,7 +486,7 @@ void ServerConfig::Apply(ServerConfig* old, const std::string &useruid)
// On first run, ports are bound later on
FailedPortList pl;
ServerInstance->BindPorts(pl);
- if (pl.size())
+ if (!pl.empty())
{
std::cout << "Warning! Some of your listener" << (pl.size() == 1 ? "s" : "") << " failed to bind:" << std::endl;
for (FailedPortList::const_iterator iter = pl.begin(); iter != pl.end(); ++iter)