Browse Source

Litecoin: Runtime paths s/bitcoin/litecoin/

0.8
Warren Togami 11 years ago
parent
commit
4f21807de8
  1. 12
      src/util.cpp

12
src/util.cpp

@ -981,7 +981,7 @@ static std::string FormatException(std::exception* pex, const char* pszThread) @@ -981,7 +981,7 @@ static std::string FormatException(std::exception* pex, const char* pszThread)
char pszModule[MAX_PATH] = "";
GetModuleFileNameA(NULL, pszModule, sizeof(pszModule));
#else
const char* pszModule = "bitcoin";
const char* pszModule = "litecoin";
#endif
if (pex)
return strprintf(
@ -1023,7 +1023,7 @@ boost::filesystem::path GetDefaultDataDir() @@ -1023,7 +1023,7 @@ boost::filesystem::path GetDefaultDataDir()
// Unix: ~/.bitcoin
#ifdef WIN32
// Windows
return GetSpecialFolderPath(CSIDL_APPDATA) / "Bitcoin";
return GetSpecialFolderPath(CSIDL_APPDATA) / "Litecoin";
#else
fs::path pathRet;
char* pszHome = getenv("HOME");
@ -1035,10 +1035,10 @@ boost::filesystem::path GetDefaultDataDir() @@ -1035,10 +1035,10 @@ boost::filesystem::path GetDefaultDataDir()
// Mac
pathRet /= "Library/Application Support";
fs::create_directory(pathRet);
return pathRet / "Bitcoin";
return pathRet / "Litecoin";
#else
// Unix
return pathRet / ".bitcoin";
return pathRet / ".litecoin";
#endif
#endif
}
@ -1079,7 +1079,7 @@ const boost::filesystem::path &GetDataDir(bool fNetSpecific) @@ -1079,7 +1079,7 @@ const boost::filesystem::path &GetDataDir(bool fNetSpecific)
boost::filesystem::path GetConfigFile()
{
boost::filesystem::path pathConfigFile(GetArg("-conf", "bitcoin.conf"));
boost::filesystem::path pathConfigFile(GetArg("-conf", "litecoin.conf"));
if (!pathConfigFile.is_complete()) pathConfigFile = GetDataDir(false) / pathConfigFile;
return pathConfigFile;
}
@ -1113,7 +1113,7 @@ void ReadConfigFile(map<string, string>& mapSettingsRet, @@ -1113,7 +1113,7 @@ void ReadConfigFile(map<string, string>& mapSettingsRet,
boost::filesystem::path GetPidFile()
{
boost::filesystem::path pathPidFile(GetArg("-pid", "bitcoind.pid"));
boost::filesystem::path pathPidFile(GetArg("-pid", "litecoind.pid"));
if (!pathPidFile.is_complete()) pathPidFile = GetDataDir() / pathPidFile;
return pathPidFile;
}

Loading…
Cancel
Save