From fdbb537d263497529c8f9deb0bb98371530839c3 Mon Sep 17 00:00:00 2001 From: Jeff Garzik Date: Thu, 27 Sep 2012 13:52:09 -0400 Subject: Add new RPC "lockunspent", to prevent spending of selected outputs and associated RPC "listlockunspent". This is a memory-only filter, which is empty when a node restarts. --- src/wallet.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/wallet.h') diff --git a/src/wallet.h b/src/wallet.h index 5e2f8e0ba..3a9fdc64d 100644 --- a/src/wallet.h +++ b/src/wallet.h @@ -119,11 +119,18 @@ public: CPubKey vchDefaultKey; + std::set setLockedCoins; + // check whether we are allowed to upgrade (or already support) to the named feature bool CanSupportFeature(enum WalletFeature wf) { return nWalletMaxVersion >= wf; } void AvailableCoins(std::vector& vCoins, bool fOnlyConfirmed=true) const; bool SelectCoinsMinConf(int64 nTargetValue, int nConfMine, int nConfTheirs, std::vector vCoins, std::set >& setCoinsRet, int64& nValueRet) const; + bool IsLockedCoin(uint256 hash, unsigned int n) const; + void LockCoin(COutPoint& output); + void UnlockCoin(COutPoint& output); + void UnlockAllCoins(); + void ListLockedCoins(std::vector& vOutpts); // keystore implementation // Generate a new key -- cgit v1.2.3