diff options
author | Philip Kaufmann <phil.kaufmann@t-online.de> | 2014-05-10 14:54:20 +0200 |
---|---|---|
committer | Philip Kaufmann <phil.kaufmann@t-online.de> | 2014-06-10 18:23:56 +0200 |
commit | ac14bcc1f12d2407516bcdfef57b2740df48381b (patch) | |
tree | 1f9164b9aea8f3e4740886d9cfbe2047299307a2 /src/util.cpp | |
parent | 3d7399cb171c2468b81a9179cb04358c56b4c7c4 (diff) |
small formatting, indentation and comment fixes
- contains zero code changes
Diffstat (limited to 'src/util.cpp')
-rw-r--r-- | src/util.cpp | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/src/util.cpp b/src/util.cpp index d106b03230..cccf2df484 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -962,13 +962,15 @@ const boost::filesystem::path &GetDataDir(bool fNetSpecific) void ClearDatadirCache() { std::fill(&pathCached[0], &pathCached[CChainParams::MAX_NETWORK_TYPES+1], - boost::filesystem::path()); + boost::filesystem::path()); } boost::filesystem::path GetConfigFile() { boost::filesystem::path pathConfigFile(GetArg("-conf", "bitcoin.conf")); - if (!pathConfigFile.is_complete()) pathConfigFile = GetDataDir(false) / pathConfigFile; + if (!pathConfigFile.is_complete()) + pathConfigFile = GetDataDir(false) / pathConfigFile; + return pathConfigFile; } @@ -1028,9 +1030,9 @@ bool RenameOver(boost::filesystem::path src, boost::filesystem::path dest) #endif /* WIN32 */ } - -// Ignores exceptions thrown by boost's create_directory if the requested directory exists. -// Specifically handles case where path p exists, but it wasn't possible for the user to write to the parent directory. +// Ignores exceptions thrown by Boost's create_directory if the requested directory exists. +// Specifically handles case where path p exists, but it wasn't possible for the user to +// write to the parent directory. bool TryCreateDirectory(const boost::filesystem::path& p) { try @@ -1381,19 +1383,19 @@ bool ParseInt32(const std::string& str, int32_t *out) void SetupEnvironment() { - #ifndef WIN32 +#ifndef WIN32 try { - #if BOOST_FILESYSTEM_VERSION == 3 +#if BOOST_FILESYSTEM_VERSION == 3 boost::filesystem::path::codecvt(); // Raises runtime error if current locale is invalid - #else // boost filesystem v2 +#else // boost filesystem v2 std::locale(); // Raises runtime error if current locale is invalid - #endif +#endif } catch(std::runtime_error &e) { setenv("LC_ALL", "C", 1); // Force C locale } - #endif +#endif } std::string DateTimeStrFormat(const char* pszFormat, int64_t nTime) |