Skip to content

Commit

Permalink
Merge pull request #206 from Jongjan88/pr2
Browse files Browse the repository at this point in the history
Fix for Boost 1_84_0
  • Loading branch information
JaredTate authored Mar 18, 2024
2 parents fff3955 + 17f403e commit 17fcaf9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/wallet/bdb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -624,7 +624,7 @@ bool BerkeleyDatabase::Backup(const std::string& strDest) const
return false;
}

fs::copy_file(pathSrc, pathDest, fs::copy_option::overwrite_if_exists);
fs::copy_file(pathSrc, pathDest, fs::copy_options::overwrite_existing);
LogPrintf("copied %s to %s\n", strFile, pathDest.string());
return true;
} catch (const fs::filesystem_error& e) {
Expand Down
6 changes: 3 additions & 3 deletions src/wallet/db.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ std::vector<fs::path> ListDatabases(const fs::path& wallet_dir)
for (auto it = fs::recursive_directory_iterator(wallet_dir, ec); it != fs::recursive_directory_iterator(); it.increment(ec)) {
if (ec) {
if (fs::is_directory(*it)) {
it.no_push();
it.disable_recursion_pending();
LogPrintf("%s: %s %s -- skipping.\n", __func__, ec.message(), it->path().string());
} else {
LogPrintf("%s: %s %s\n", __func__, ec.message(), it->path().string());
Expand All @@ -37,7 +37,7 @@ std::vector<fs::path> ListDatabases(const fs::path& wallet_dir)
(IsBDBFile(BDBDataFile(it->path())) || IsSQLiteFile(SQLiteDataFile(it->path())))) {
// Found a directory which contains wallet.dat btree file, add it as a wallet.
paths.emplace_back(path);
} else if (it.level() == 0 && it->symlink_status().type() == fs::regular_file && IsBDBFile(it->path())) {
} else if (it.depth() == 0 && it->symlink_status().type() == fs::regular_file && IsBDBFile(it->path())) {
if (it->path().filename() == "wallet.dat") {
// Found top-level wallet.dat btree file, add top level directory ""
// as a wallet.
Expand All @@ -52,7 +52,7 @@ std::vector<fs::path> ListDatabases(const fs::path& wallet_dir)
}
} catch (const std::exception& e) {
LogPrintf("%s: Error scanning %s: %s\n", __func__, it->path().string(), e.what());
it.no_push();
it.disable_recursion_pending();
}
}

Expand Down

0 comments on commit 17fcaf9

Please sign in to comment.