diff options
| author | Wladimir J. van der Laan <[email protected]> | 2016-03-14 11:18:02 +0100 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2016-03-14 11:26:52 +0100 |
| commit | 56d2c4e0fee3372535a4b4436cebca94f2eda0ad (patch) | |
| tree | 14cf59303763e6e1f53c350182247c8f7f4653da /src/util.cpp | |
| parent | Merge #7668: Fix history deletion bug after font size change (diff) | |
| parent | Move GetTempPath() to testutil. (diff) | |
| download | discoin-56d2c4e0fee3372535a4b4436cebca94f2eda0ad.tar.xz discoin-56d2c4e0fee3372535a4b4436cebca94f2eda0ad.zip | |
Merge #7667: Move GetTempPath() to testutil
2fdaa25 Move GetTempPath() to testutil. (Mustafa)
393b22e Add a source file for unit test utils. (Mustafa)
Diffstat (limited to 'src/util.cpp')
| -rw-r--r-- | src/util.cpp | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/src/util.cpp b/src/util.cpp index 492697e12..59f58f2c5 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -738,28 +738,6 @@ boost::filesystem::path GetSpecialFolderPath(int nFolder, bool fCreate) } #endif -boost::filesystem::path GetTempPath() { -#if BOOST_FILESYSTEM_VERSION == 3 - return boost::filesystem::temp_directory_path(); -#else - // TODO: remove when we don't support filesystem v2 anymore - boost::filesystem::path path; -#ifdef WIN32 - char pszPath[MAX_PATH] = ""; - - if (GetTempPathA(MAX_PATH, pszPath)) - path = boost::filesystem::path(pszPath); -#else - path = boost::filesystem::path("/tmp"); -#endif - if (path.empty() || !boost::filesystem::is_directory(path)) { - LogPrintf("GetTempPath(): failed to find temp path\n"); - return boost::filesystem::path(""); - } - return path; -#endif -} - void runCommand(const std::string& strCommand) { int nErr = ::system(strCommand.c_str()); |