This commit is contained in:
Markus 2019-11-03 15:38:23 +01:00
parent 61995f0587
commit 12337b4963
2 changed files with 10 additions and 4 deletions

View File

@ -8,7 +8,8 @@ int main(int argc, char *argv[])
if(res == -1)
return 0;
else if(res != 0) {
std::cout << " => Error: Das Auswerten der Parameter ist fehlgeschlagen!" << std::endl;
if(settings.debugMode)
std::cout << " => Error: Das Auswerten der Parameter ist fehlgeschlagen!" << std::endl;
return res;
} else {
return mainProgram.start(&settings);

View File

@ -218,8 +218,13 @@ int loadDefaulOptions(Settings &settings)
std::cout << " => Warnung: Bitte Info-Texte mit '#' am Anfang: Ungültige Option '" << line << "'." << std::endl;
continue;
}
std::string what = line.substr(0, line.find("=")), data = line.substr(line.find("=") + 1, line.length() - line.find("=") -1);

//extrahiere einstellung und wert aus Zeile:
std::string what = line.substr(0, line.find("=")),
data = line.substr(line.find("=") + 1, line.length() - line.find("=") -1);

if(what == "") {
continue;

} else if (what == "Socks5Proxy") {
if(setS5ProxytoSettings(settings, data) != 0)
@ -359,10 +364,10 @@ int unterOption_help(Settings &settings)
std::cout << "Verzeichnisse:" << std::endl
<< "\tOrdner zum zwischenspeichern der Cookies, AccountNummer" << std::endl
<< "\tund des letzten Update Datums:" << std::endl
<< " => > '" << std::string(settings.cookieFilePath).erase(settings.cookieFilePath.find_last_of(settings.pathSymbol)) << settings.pathSymbol << "'" << std::endl
<< " => > '" << std::string(settings.cookieFilePath).erase(settings.cookieFilePath.find_last_of(settings.pathSymbol) + 1) << "'" << std::endl
<< "\tOrdner zum speichern der Accounts, Default-Einstellungen" << std::endl
<< "\tund der Serienliste:" << std::endl
<< " => > '" << std::string(settings.defaultsFilePath).erase(settings.defaultsFilePath.find_last_of(settings.pathSymbol)) << settings.pathSymbol << "'" << std::endl;
<< " => > '" << std::string(settings.defaultsFilePath).erase(settings.defaultsFilePath.find_last_of(settings.pathSymbol) + 1) << "'" << std::endl;

return -1;
}