From 24d4fb82532b4ce742c6931b543048a750713f98 Mon Sep 17 00:00:00 2001 From: Ulukyn Date: Thu, 2 Apr 2020 17:23:44 +0200 Subject: [PATCH] Fixed: Prevent crash if no StartupVerify config --- code/ryzom/client/src/login.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/code/ryzom/client/src/login.cpp b/code/ryzom/client/src/login.cpp index c9c1fdeaf..d3c0a629a 100644 --- a/code/ryzom/client/src/login.cpp +++ b/code/ryzom/client/src/login.cpp @@ -161,8 +161,10 @@ CLoginStateMachine LoginSM; bool CStartupHttpClient::connectToLogin() { - return connect(ClientCfg.ConfigFile.getVar("StartupHost").asString(0)) - && verifyServer(ClientCfg.ConfigFile.getVar("StartupVerify").asBool(0)); + bool checkConnect = connect(ClientCfg.ConfigFile.getVar("StartupHost").asString(0)); + + if (ClientCfg.ConfigFile.exists("StartupVerify")) + checkConnect = checkConnect && verifyServer(ClientCfg.ConfigFile.getVar("StartupVerify").asBool(0)); } CStartupHttpClient HttpClient; @@ -1969,7 +1971,7 @@ class CAHOpenURL : public IActionHandler } // modify existing languages - + // old site string::size_type pos_lang = url.find("/en/");