Fixed: Prevent crash if no StartupVerify config

fix-media-player
Ulukyn 5 years ago
parent b5ffa8becd
commit 24d4fb8253

@ -161,8 +161,10 @@ CLoginStateMachine LoginSM;
bool CStartupHttpClient::connectToLogin() bool CStartupHttpClient::connectToLogin()
{ {
return connect(ClientCfg.ConfigFile.getVar("StartupHost").asString(0)) bool checkConnect = connect(ClientCfg.ConfigFile.getVar("StartupHost").asString(0));
&& verifyServer(ClientCfg.ConfigFile.getVar("StartupVerify").asBool(0));
if (ClientCfg.ConfigFile.exists("StartupVerify"))
checkConnect = checkConnect && verifyServer(ClientCfg.ConfigFile.getVar("StartupVerify").asBool(0));
} }
CStartupHttpClient HttpClient; CStartupHttpClient HttpClient;
@ -1969,7 +1971,7 @@ class CAHOpenURL : public IActionHandler
} }
// modify existing languages // modify existing languages
// old site // old site
string::size_type pos_lang = url.find("/en/"); string::size_type pos_lang = url.find("/en/");

Loading…
Cancel
Save