fix erase expired tx on wallet load

This commit is contained in:
blackjok3r
2019-05-19 00:16:31 +08:00
parent 02a3f08894
commit c0bc4dc7f8

View File

@@ -2874,9 +2874,9 @@ void CWallet::ReacceptWalletTransactions()
bool invalid = state.IsInvalid(nDoS);
// log rejection and deletion
// printf("ERROR reaccepting wallet transaction %s to mempool, reason: %s, DoS: %d\n", wtx.GetHash().ToString().c_str(), state.GetRejectReason().c_str(), nDoS);
//printf("ERROR reaccepting wallet transaction %s to mempool, reason: %s, DoS: %d\n", wtx.GetHash().ToString().c_str(), state.GetRejectReason().c_str(), nDoS);
if (!wtx.IsCoinBase() && invalid && nDoS > 0)
if (!wtx.IsCoinBase() && invalid && nDoS > 0 && state.GetRejectReason() != "tx-overwinter-expired")
{
LogPrintf("erasing transaction %s\n", wtx.GetHash().GetHex().c_str());
vwtxh.push_back(wtx.GetHash());