Patch ZNC core for more control over singleton...

This commit is contained in:
Ingmar Runge
2014-02-06 22:21:44 +01:00
parent 200c5da15f
commit 4c505946ac
3 changed files with 24 additions and 8 deletions
+4 -1
View File
@@ -193,6 +193,8 @@ int main(int argc, char** argv) {
return 1;
}
CZNC::CreateInstance();
CZNC* pZNC = &CZNC::Get();
pZNC->InitDirs(((argc) ? argv[0] : ""), sDataDir);
@@ -264,7 +266,8 @@ int main(int argc, char** argv) {
/* Fall through to normal bootup */
}
if (!pZNC->ParseConfig(sConfig)) {
CString sConfigError;
if (!pZNC->ParseConfig(sConfig, sConfigError)) {
CUtils::PrintError("Unrecoverable config error.");
delete pZNC;
return 1;