Changeset View
Changeset View
Standalone View
Standalone View
src/wallet/wallet.cpp
Show All 38 Lines | |||||
#include <wallet/fees.h> | #include <wallet/fees.h> | ||||
#include <boost/algorithm/string/replace.hpp> | #include <boost/algorithm/string/replace.hpp> | ||||
#include <algorithm> | #include <algorithm> | ||||
#include <cassert> | #include <cassert> | ||||
#include <future> | #include <future> | ||||
const std::map<uint64_t, std::string> WALLET_FLAG_CAVEATS{ | |||||
{WALLET_FLAG_AVOID_REUSE, | |||||
"You need to rescan the blockchain in order to correctly mark used " | |||||
"destinations in the past. Until this is done, some destinations may " | |||||
"be considered unused, even if the opposite is the case."}, | |||||
}; | |||||
static RecursiveMutex cs_wallets; | static RecursiveMutex cs_wallets; | ||||
static std::vector<std::shared_ptr<CWallet>> vpwallets GUARDED_BY(cs_wallets); | static std::vector<std::shared_ptr<CWallet>> vpwallets GUARDED_BY(cs_wallets); | ||||
bool AddWallet(const std::shared_ptr<CWallet> &wallet) { | bool AddWallet(const std::shared_ptr<CWallet> &wallet) { | ||||
LOCK(cs_wallets); | LOCK(cs_wallets); | ||||
assert(wallet); | assert(wallet); | ||||
std::vector<std::shared_ptr<CWallet>>::const_iterator i = | std::vector<std::shared_ptr<CWallet>>::const_iterator i = | ||||
std::find(vpwallets.begin(), vpwallets.end(), wallet); | std::find(vpwallets.begin(), vpwallets.end(), wallet); | ||||
▲ Show 20 Lines • Show All 4,957 Lines • Show Last 20 Lines |