| 397 | } |
| 398 | |
| 399 | bool CBaseParams::LoadParamsFromConfigFile(int argc, const char* const argv[]) { |
| 400 | ParseParameters(argc, argv); |
| 401 | if (!boost::filesystem::is_directory(GetDataDir(false))) { |
| 402 | fprintf(stderr, "Error: Specified data directory \"%s\" does not exist.\n", CBaseParams::m_mapArgs["-datadir"].c_str()); |
| 403 | return false; |
| 404 | } |
| 405 | |
| 406 | try { |
| 407 | ReadConfigFile(CBaseParams::m_mapArgs, CBaseParams::m_mapMultiArgs); |
| 408 | } catch (std::exception &e) { |
| 409 | fprintf(stderr, "Error: reading configuration file: %s\n", e.what()); |
| 410 | return false; |
| 411 | } |
| 412 | |
| 413 | return true; |
| 414 | } |
| 415 | |
| 416 | CBaseParams::CBaseParams() { |
| 417 | fImporting = false; |
nothing calls this directly
no test coverage detected