aboutsummaryrefslogtreecommitdiff
path: root/db.cpp
diff options
context:
space:
mode:
authorGavin Andresen <[email protected]>2010-09-06 21:51:27 -0400
committerGavin Andresen <[email protected]>2010-09-06 21:51:27 -0400
commita2120986ff5095b55553ecb8c191b700970e61f4 (patch)
tree22ab42c13a2b9c561661d2375602b5ec35de24da /db.cpp
parentMerge remote branch 'remotes/svn/trunk' into svn (diff)
parentcleanup, (diff)
downloaddiscoin-a2120986ff5095b55553ecb8c191b700970e61f4.tar.xz
discoin-a2120986ff5095b55553ecb8c191b700970e61f4.zip
Merge remote branch 'refs/remotes/svn/trunk' into svn
Diffstat (limited to 'db.cpp')
-rw-r--r--db.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/db.cpp b/db.cpp
index 56ec9ee6e..6b3af2579 100644
--- a/db.cpp
+++ b/db.cpp
@@ -820,10 +820,15 @@ void BackupWallet(const string& strDest)
mapFileUseCount.erase(strFile);
// Copy wallet.dat
+ filesystem::path pathSrc(GetDataDir() + "/" + strFile);
filesystem::path pathDest(strDest);
if (filesystem::is_directory(pathDest))
pathDest = pathDest / strFile;
- filesystem::copy_file(filesystem::path(GetDataDir() + "/" + strFile), pathDest, filesystem::copy_option::overwrite_if_exists);
+#if BOOST_VERSION >= 104000
+ filesystem::copy_file(pathSrc, pathDest, filesystem::copy_option::overwrite_if_exists);
+#else
+ filesystem::copy_file(pathSrc, pathDest);
+#endif
printf("copied wallet.dat to %s\n", pathDest.string().c_str());
return;