mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-03-10 01:01:02 +00:00
* drop mapMultiArgs : it's not used anywhere
This commit is contained in:
parent
05043f30dc
commit
1d5194a138
@ -65,7 +65,7 @@ namespace i2p
|
||||
|
||||
LogPrint(eLogInfo, "i2pd v", VERSION, " starting");
|
||||
LogPrint(eLogDebug, "FS: data directory: ", i2p::util::filesystem::GetDataDir().string());
|
||||
i2p::util::filesystem::ReadConfigFile(i2p::util::config::mapArgs, i2p::util::config::mapMultiArgs);
|
||||
i2p::util::filesystem::ReadConfigFile(i2p::util::config::mapArgs);
|
||||
|
||||
isDaemon = i2p::util::config::GetArg("-daemon", 0);
|
||||
isLogging = i2p::util::config::GetArg("-log", 1);
|
||||
|
7
util.cpp
7
util.cpp
@ -70,12 +70,10 @@ namespace util
|
||||
namespace config
|
||||
{
|
||||
std::map<std::string, std::string> mapArgs;
|
||||
std::map<std::string, std::vector<std::string> > mapMultiArgs;
|
||||
|
||||
void OptionParser(int argc, const char* const argv[])
|
||||
{
|
||||
mapArgs.clear();
|
||||
mapMultiArgs.clear();
|
||||
for (int i = 1; i < argc; i++)
|
||||
{
|
||||
std::string strKey (argv[i]);
|
||||
@ -96,7 +94,6 @@ namespace config
|
||||
break;
|
||||
|
||||
mapArgs[strKey] = strValue;
|
||||
mapMultiArgs[strKey].push_back(strValue);
|
||||
}
|
||||
|
||||
BOOST_FOREACH(PAIRTYPE(const std::string,std::string)& entry, mapArgs)
|
||||
@ -196,8 +193,7 @@ namespace filesystem
|
||||
return pathTunnelsConfigFile;
|
||||
}
|
||||
|
||||
void ReadConfigFile(std::map<std::string, std::string>& mapSettingsRet,
|
||||
std::map<std::string, std::vector<std::string> >& mapMultiSettingsRet)
|
||||
void ReadConfigFile(std::map<std::string, std::string>& mapSettingsRet)
|
||||
{
|
||||
boost::filesystem::ifstream streamConfig(GetConfigFile());
|
||||
if (!streamConfig.good())
|
||||
@ -214,7 +210,6 @@ namespace filesystem
|
||||
{
|
||||
mapSettingsRet[strKey] = it->value[0];
|
||||
}
|
||||
mapMultiSettingsRet[strKey].push_back(it->value[0]);
|
||||
}
|
||||
}
|
||||
|
||||
|
4
util.h
4
util.h
@ -17,7 +17,6 @@ namespace util
|
||||
namespace config
|
||||
{
|
||||
extern std::map<std::string, std::string> mapArgs;
|
||||
extern std::map<std::string, std::vector<std::string> > mapMultiArgs;
|
||||
void OptionParser(int argc, const char* const argv[]);
|
||||
int GetArg(const std::string& strArg, int nDefault);
|
||||
std::string GetArg(const std::string& strArg, const std::string& strDefault);
|
||||
@ -34,8 +33,7 @@ namespace util
|
||||
boost::filesystem::path GetDefaultDataDir();
|
||||
boost::filesystem::path GetConfigFile();
|
||||
boost::filesystem::path GetTunnelsConfigFile();
|
||||
void ReadConfigFile(std::map<std::string, std::string>& mapSettingsRet,
|
||||
std::map<std::string, std::vector<std::string> >& mapMultiSettingsRet);
|
||||
void ReadConfigFile(std::map<std::string, std::string>& mapSettingsRet);
|
||||
boost::filesystem::path GetCertificatesDir();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user