mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-17 13:01:42 +00:00
Changed: Use ClientCfg.getDefaultConfigLocation to get location of client root
--HG-- branch : develop
This commit is contained in:
parent
3487bf16ff
commit
3c1a41d2b3
1 changed files with 7 additions and 3 deletions
|
@ -125,10 +125,14 @@ CPatchManager::CPatchManager() : State("t_state"), DataScanState("t_data_scan_st
|
|||
UpgradeBatchFilename = "upgd_nl.sh";
|
||||
#endif
|
||||
|
||||
// use application directory by default
|
||||
std::string rootPath = Args.getProgramPath();
|
||||
std::string rootPath;
|
||||
|
||||
if (!CFile::fileExists(rootPath + "client_default.cfg"))
|
||||
if (ClientCfg.getDefaultConfigLocation(rootPath))
|
||||
{
|
||||
// use same directory as client_default.cfg
|
||||
rootPath = CFile::getPath(rootPath);
|
||||
}
|
||||
else
|
||||
{
|
||||
// use current directory
|
||||
rootPath = CPath::getCurrentPath();
|
||||
|
|
Loading…
Reference in a new issue