diff options
author | Alexander Harkness <me@bearbin.net> | 2015-05-19 11:53:44 +0200 |
---|---|---|
committer | Alexander Harkness <me@bearbin.net> | 2015-05-19 11:53:44 +0200 |
commit | fff5efedc331922bd871eddef886a75177e67d9a (patch) | |
tree | ea38ffc8455c2179ad8a817c5c988d2b68be2051 /src/RCONServer.cpp | |
parent | Removed tip4commit, it's not used anymore. (diff) | |
parent | Add support for setting ports through command line (diff) | |
download | cuberite-fff5efedc331922bd871eddef886a75177e67d9a.tar cuberite-fff5efedc331922bd871eddef886a75177e67d9a.tar.gz cuberite-fff5efedc331922bd871eddef886a75177e67d9a.tar.bz2 cuberite-fff5efedc331922bd871eddef886a75177e67d9a.tar.lz cuberite-fff5efedc331922bd871eddef886a75177e67d9a.tar.xz cuberite-fff5efedc331922bd871eddef886a75177e67d9a.tar.zst cuberite-fff5efedc331922bd871eddef886a75177e67d9a.zip |
Diffstat (limited to 'src/RCONServer.cpp')
-rw-r--r-- | src/RCONServer.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/RCONServer.cpp b/src/RCONServer.cpp index 685bd92f5..c5dc9b69b 100644 --- a/src/RCONServer.cpp +++ b/src/RCONServer.cpp @@ -134,15 +134,15 @@ cRCONServer::~cRCONServer() -void cRCONServer::Initialize(cIniFile & a_IniFile) +void cRCONServer::Initialize(cSettingsRepositoryInterface & a_Settings) { - if (!a_IniFile.GetValueSetB("RCON", "Enabled", false)) + if (!a_Settings.GetValueSetB("RCON", "Enabled", false)) { return; } // Read the password, don't allow an empty one: - m_Password = a_IniFile.GetValueSet("RCON", "Password", ""); + m_Password = a_Settings.GetValueSet("RCON", "Password", ""); if (m_Password.empty()) { LOGWARNING("RCON is requested, but the password is not set. RCON is now disabled."); @@ -150,7 +150,7 @@ void cRCONServer::Initialize(cIniFile & a_IniFile) } // Read the listening ports for RCON from config: - AStringVector Ports = ReadUpgradeIniPorts(a_IniFile, "RCON", "Ports", "PortsIPv4", "PortsIPv6", "25575"); + AStringVector Ports = ReadUpgradeIniPorts(a_Settings, "RCON", "Ports", "PortsIPv4", "PortsIPv6", "25575"); // Start listening on each specified port: for (auto port: Ports) |