1
0

WebAdmin uses the new HTTP functionality.

This is a partial implementation of #183.
This commit is contained in:
madmaxoft
2013-10-05 23:08:16 +02:00
parent 20d07a683f
commit b5c90d7b20
10 changed files with 415 additions and 302 deletions

View File

@@ -127,25 +127,16 @@ cHTTPServer::cHTTPServer(void) :
bool cHTTPServer::Initialize(cIniFile & a_IniFile)
bool cHTTPServer::Initialize(const AString & a_PortsIPv4, const AString & a_PortsIPv6)
{
if (!a_IniFile.GetValueSetB("WebAdmin", "Enabled", false))
{
// The WebAdmin is disabled
return true;
}
bool HasAnyPort;
HasAnyPort = m_ListenThreadIPv4.Initialize(a_IniFile.GetValueSet("WebAdmin", "Port", "8081"));
HasAnyPort = m_ListenThreadIPv6.Initialize(a_IniFile.GetValueSet("WebAdmin", "PortsIPv6", "8082, 3300")) || HasAnyPort;
HasAnyPort = m_ListenThreadIPv4.Initialize(a_PortsIPv4);
HasAnyPort = m_ListenThreadIPv6.Initialize(a_PortsIPv6) || HasAnyPort;
if (!HasAnyPort)
{
LOG("WebAdmin is disabled");
return false;
}
// DEBUG:
return Start(g_DebugCallbacks);
return true;
}