aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/salvage.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/wallet/salvage.cpp')
-rw-r--r--src/wallet/salvage.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/wallet/salvage.cpp b/src/wallet/salvage.cpp
index 09a9ec68cd..ea045eb6d8 100644
--- a/src/wallet/salvage.cpp
+++ b/src/wallet/salvage.cpp
@@ -119,7 +119,7 @@ bool RecoverDatabaseFile(const fs::path& file_path, bilingual_str& error, std::v
return false;
}
- std::unique_ptr<Db> pdbCopy = MakeUnique<Db>(env->dbenv.get(), 0);
+ std::unique_ptr<Db> pdbCopy = std::make_unique<Db>(env->dbenv.get(), 0);
int ret = pdbCopy->open(nullptr, // Txn pointer
filename.c_str(), // Filename
"main", // Logical db name
@@ -154,8 +154,8 @@ bool RecoverDatabaseFile(const fs::path& file_path, bilingual_str& error, std::v
warnings.push_back(strprintf(Untranslated("WARNING: WalletBatch::Recover skipping %s: %s"), strType, strErr));
continue;
}
- Dbt datKey(&row.first[0], row.first.size());
- Dbt datValue(&row.second[0], row.second.size());
+ Dbt datKey(row.first.data(), row.first.size());
+ Dbt datValue(row.second.data(), row.second.size());
int ret2 = pdbCopy->put(ptxn, &datKey, &datValue, DB_NOOVERWRITE);
if (ret2 > 0)
fSuccess = false;