aboutsummaryrefslogtreecommitdiff
path: root/src/util.cpp
diff options
context:
space:
mode:
authorMustafa <mus@musalbas.com>2016-03-11 15:04:05 +0000
committerMustafa <mus@musalbas.com>2016-03-11 15:04:05 +0000
commit2fdaa255295402d24bb16a72b07cc72c9a5df8e4 (patch)
treefa14ad9de0a21b9a1b9fa2203cbb90baed117eee /src/util.cpp
parent393b22eacb8aff58aaa4da48085f3ea37424ba59 (diff)
downloadbitcoin-2fdaa255295402d24bb16a72b07cc72c9a5df8e4.tar.xz
Move GetTempPath() to testutil.
Diffstat (limited to 'src/util.cpp')
-rw-r--r--src/util.cpp22
1 files changed, 0 insertions, 22 deletions
diff --git a/src/util.cpp b/src/util.cpp
index 492697e12f..59f58f2c55 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());