From 2c92cbbcf9f4f645a5318330d5077f51b9df0f4b Mon Sep 17 00:00:00 2001 From: Mrs-X Date: Tue, 15 Nov 2016 22:01:02 +0100 Subject: [PATCH] Don't try to spend immature coins (it'll fail anyway...) --- src/wallet.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wallet.cpp b/src/wallet.cpp index e48275e4170d..2ec031231be0 100644 --- a/src/wallet.cpp +++ b/src/wallet.cpp @@ -1571,7 +1571,7 @@ void CWallet::AvailableCoins(vector& vCoins, bool fOnlyConfirmed, const if (fOnlyConfirmed && !pcoin->IsTrusted()) continue; - if (pcoin->IsCoinBase() && pcoin->GetBlocksToMaturity() > 0) + if ((pcoin->IsCoinBase() || pcoin->IsCoinStake()) && pcoin->GetBlocksToMaturity() > 0) continue; int nDepth = pcoin->GetDepthInMainChain(false);