| 2743 | } |
| 2744 | |
| 2745 | bool CWallet::LockCoin(const COutPoint& output, bool persist) |
| 2746 | { |
| 2747 | AssertLockHeld(cs_wallet); |
| 2748 | LoadLockedCoin(output, persist); |
| 2749 | if (persist) { |
| 2750 | WalletBatch batch(GetDatabase()); |
| 2751 | return batch.WriteLockedUTXO(output); |
| 2752 | } |
| 2753 | return true; |
| 2754 | } |
| 2755 | |
| 2756 | bool CWallet::UnlockCoin(const COutPoint& output) |
| 2757 | { |