diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2014-05-08 10:40:49 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2014-05-08 10:48:07 +0200 |
commit | 0ecd8aae203f87850672d4cd1166dfd77e4aeb72 (patch) | |
tree | 05839997b0375e825057c7e6a7dcaf04ddf526e6 /src | |
parent | 69e264b6f80013595f6e7669947856b5432bdf6e (diff) | |
parent | 3e1cf9b6f68bac2456258ea7b12f2342c760a223 (diff) | |
download | bitcoin-0ecd8aae203f87850672d4cd1166dfd77e4aeb72.tar.xz |
Merge pull request #4131
3e1cf9b add DEFAULT_TRANSACTION_FEE constant in wallet (Philip Kaufmann)
Diffstat (limited to 'src')
-rw-r--r-- | src/qt/optionsmodel.cpp | 2 | ||||
-rw-r--r-- | src/wallet.cpp | 4 | ||||
-rw-r--r-- | src/wallet.h | 2 |
3 files changed, 5 insertions, 3 deletions
diff --git a/src/qt/optionsmodel.cpp b/src/qt/optionsmodel.cpp index 74c6b10ce2..d024af73c8 100644 --- a/src/qt/optionsmodel.cpp +++ b/src/qt/optionsmodel.cpp @@ -93,7 +93,7 @@ void OptionsModel::Init() // Wallet #ifdef ENABLE_WALLET if (!settings.contains("nTransactionFee")) - settings.setValue("nTransactionFee", 0); + settings.setValue("nTransactionFee", DEFAULT_TRANSACTION_FEE); nTransactionFee = settings.value("nTransactionFee").toLongLong(); // if -paytxfee is set, this will be overridden later in init.cpp if (mapArgs.count("-paytxfee")) addOverriddenOption("-paytxfee"); diff --git a/src/wallet.cpp b/src/wallet.cpp index 7cf2361096..418720de93 100644 --- a/src/wallet.cpp +++ b/src/wallet.cpp @@ -6,9 +6,9 @@ #include "wallet.h" #include "base58.h" +#include "checkpoints.h" #include "coincontrol.h" #include "net.h" -#include "checkpoints.h" #include <boost/algorithm/string/replace.hpp> #include <openssl/rand.h> @@ -16,7 +16,7 @@ using namespace std; // Settings -int64_t nTransactionFee = 0; +int64_t nTransactionFee = DEFAULT_TRANSACTION_FEE; bool bSpendZeroConfChange = true; ////////////////////////////////////////////////////////////////////////////// diff --git a/src/wallet.h b/src/wallet.h index 5fd56d0af6..b2c06d3f61 100644 --- a/src/wallet.h +++ b/src/wallet.h @@ -27,6 +27,8 @@ extern int64_t nTransactionFee; extern bool bSpendZeroConfChange; +// -paytxfee default +static const int64_t DEFAULT_TRANSACTION_FEE = 0; // -paytxfee will warn if called with a higher fee than this amount (in satoshis) per KB static const int nHighTransactionFeeWarning = 0.01 * COIN; |