From 3f5033eb1380952041e0cf365e09e7dc1a14f54a Mon Sep 17 00:00:00 2001 From: Sunny King Date: Thu, 19 Apr 2012 16:41:38 +0100 Subject: [PATCH] PPCoin: Fix CreateCoinStake() bug from 747f99fb causing SignSignature()'s first assert firing in script.cpp --- src/wallet.cpp | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/src/wallet.cpp b/src/wallet.cpp index 58e1baf..1b30be8 100644 --- a/src/wallet.cpp +++ b/src/wallet.cpp @@ -1114,7 +1114,7 @@ bool CWallet::CreateCoinStake(CScript scriptPubKey, unsigned int nBits, CTransac break; } } - if (nCredit > nBalance - nBalanceReserve) + if (nCredit == 0 || nCredit > nBalance - nBalanceReserve) return false; // Calculate coin age reward { -- 1.7.1