From 2f1a30c63e421b191c62059132b1cd40c24bd4d5 Mon Sep 17 00:00:00 2001 From: Johnson Lau Date: Fri, 27 Apr 2018 01:24:48 +0800 Subject: Fix MAX_STANDARD_TX_WEIGHT check As suggested by the constant name and its comment in policy.h, a transaction with a weight of exactly MAX_STANDARD_TX_WEIGHT should be allowed --- src/wallet/wallet.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/wallet') diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp index 9533e6ff56..5bdb3fe294 100644 --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -3053,7 +3053,7 @@ bool CWallet::CreateTransaction(const std::vector& vecSend, CTransac tx = MakeTransactionRef(std::move(txNew)); // Limit size - if (GetTransactionWeight(*tx) >= MAX_STANDARD_TX_WEIGHT) + if (GetTransactionWeight(*tx) > MAX_STANDARD_TX_WEIGHT) { strFailReason = _("Transaction too large"); return false; -- cgit v1.2.3