mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-30 04:37:50 +02:00
Make tunnels.cfg configurable
This commit is contained in:
parent
14c5753261
commit
3d489a2996
5 changed files with 18 additions and 4 deletions
|
@ -185,6 +185,14 @@ namespace filesystem
|
|||
return pathConfigFile;
|
||||
}
|
||||
|
||||
boost::filesystem::path GetTunnelsConfigFile()
|
||||
{
|
||||
boost::filesystem::path pathTunnelsConfigFile(i2p::util::config::GetArg("-tunnelscfg", "tunnels.cfg"));
|
||||
if(!pathTunnelsConfigFile.is_complete())
|
||||
pathTunnelsConfigFile = GetDataDir() / pathTunnelsConfigFile;
|
||||
return pathTunnelsConfigFile;
|
||||
}
|
||||
|
||||
boost::filesystem::path GetDefaultDataDir()
|
||||
{
|
||||
// Windows < Vista: C:\Documents and Settings\Username\Application Data\i2pd
|
||||
|
|
|
@ -70,6 +70,11 @@ namespace util
|
|||
*/
|
||||
boost::filesystem::path GetConfigFile();
|
||||
|
||||
/**
|
||||
* @return the path of the tunnels configuration file
|
||||
*/
|
||||
boost::filesystem::path GetTunnelsConfigFile();
|
||||
|
||||
/**
|
||||
* @return the default directory for i2pd data
|
||||
*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue