Browse Source
Throw an error if zcash.conf is missing
An empty zcash.conf is sufficient to bypass this error.
1.0.8
Jack Grigg
8 years ago
No known key found for this signature in database
GPG Key ID: 6A6914DAFBEA00DA
2 changed files with
5 additions and
1 deletions
-
src/util.cpp
-
src/util.h
|
|
@ -534,7 +534,7 @@ void ReadConfigFile(map<string, string>& mapSettingsRet, |
|
|
|
{ |
|
|
|
boost::filesystem::ifstream streamConfig(GetConfigFile()); |
|
|
|
if (!streamConfig.good()) |
|
|
|
return; // No zcash.conf file is OK
|
|
|
|
throw missing_zcash_conf(); |
|
|
|
|
|
|
|
set<string> setOptions; |
|
|
|
setOptions.insert("*"); |
|
|
|
|
|
@ -127,6 +127,10 @@ boost::filesystem::path GetConfigFile(); |
|
|
|
boost::filesystem::path GetPidFile(); |
|
|
|
void CreatePidFile(const boost::filesystem::path &path, pid_t pid); |
|
|
|
#endif |
|
|
|
class missing_zcash_conf : public std::runtime_error { |
|
|
|
public: |
|
|
|
missing_zcash_conf() : std::runtime_error("Missing zcash.conf") { } |
|
|
|
}; |
|
|
|
void ReadConfigFile(std::map<std::string, std::string>& mapSettingsRet, std::map<std::string, std::vector<std::string> >& mapMultiSettingsRet); |
|
|
|
#ifdef WIN32 |
|
|
|
boost::filesystem::path GetSpecialFolderPath(int nFolder, bool fCreate = true); |
|
|
|