Skip to content

Commit 285cf7a

Browse files
committed
Merge pull request #3412
c3a7f51 Move `verifymessage` from rpcwallet to rpcmisc (Wladimir J. van der Laan) 723a03d Move `createmultisig` from rpcwallet to rpcmisc (Wladimir J. van der Laan) 452955f Move `validateaddress` from rpcwallet to rpcmisc (Wladimir J. van der Laan) cd7fa8b Move `nTransactionFee` from main.cpp to wallet.cpp (Wladimir J. van der Laan) a943bde Move `settxfee` from rpcblockchain to rpcwallet (Wladimir J. van der Laan) 16bc9aa Move `getinfo` from rpcnet to rpcmisc (Wladimir J. van der Laan) 652e156 add new RPC implementation file `rpcmisc.cpp` (Wladimir J. van der Laan)
2 parents 636a42b + c3a7f51 commit 285cf7a

File tree

13 files changed

+366
-329
lines changed

13 files changed

+366
-329
lines changed

src/Makefile.am

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ libbitcoin_server_a_SOURCES = \
5353
noui.cpp \
5454
rpcblockchain.cpp \
5555
rpcmining.cpp \
56+
rpcmisc.cpp \
5657
rpcnet.cpp \
5758
rpcrawtransaction.cpp \
5859
txdb.cpp \

src/init.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -535,6 +535,7 @@ bool AppInit2(boost::thread_group& threadGroup, bool fForceServer)
535535
return InitError(strprintf(_("Invalid amount for -minrelaytxfee=<amount>: '%s'"), mapArgs["-minrelaytxfee"].c_str()));
536536
}
537537

538+
#ifdef ENABLE_WALLET
538539
if (mapArgs.count("-paytxfee"))
539540
{
540541
if (!ParseMoney(mapArgs["-paytxfee"], nTransactionFee))
@@ -543,7 +544,6 @@ bool AppInit2(boost::thread_group& threadGroup, bool fForceServer)
543544
InitWarning(_("Warning: -paytxfee is set very high! This is the transaction fee you will pay if you send a transaction."));
544545
}
545546

546-
#ifdef ENABLE_WALLET
547547
strWalletFile = GetArg("-wallet", "wallet.dat");
548548
#endif
549549
// ********************************************************* Step 4: application initialization: dir lock, daemonize, pidfile, debug log

src/main.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,6 @@ CScript COINBASE_FLAGS;
6767

6868
const string strMessageMagic = "Bitcoin Signed Message:\n";
6969

70-
// Settings
71-
int64_t nTransactionFee = 0;
72-
7370
// Internal stuff
7471
namespace {
7572
struct CBlockIndexWorkComparator

src/main.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,6 @@ extern bool fTxIndex;
9696
extern unsigned int nCoinCacheSize;
9797
extern bool fHaveGUI;
9898

99-
// Settings
100-
extern int64_t nTransactionFee;
101-
10299
// Minimum disk space required - used in CheckDiskSpace()
103100
static const uint64_t nMinDiskSpace = 52428800;
104101

src/qt/bitcoin.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#include "main.h"
1818
#include "ui_interface.h"
1919
#include "util.h"
20+
#include "wallet.h"
2021

2122
#include <stdint.h>
2223

src/qt/optionsmodel.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include "init.h"
1515
#include "main.h"
1616
#include "net.h"
17+
#include "wallet.h"
1718
#include "walletdb.h"
1819

1920
#include <QSettings>

src/rpcblockchain.cpp

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -127,30 +127,6 @@ Value getdifficulty(const Array& params, bool fHelp)
127127
}
128128

129129

130-
Value settxfee(const Array& params, bool fHelp)
131-
{
132-
if (fHelp || params.size() < 1 || params.size() > 1)
133-
throw runtime_error(
134-
"settxfee amount\n"
135-
"\nSet the transaction fee. 'amount' is a real and is rounded to the nearest 0.00000001\n"
136-
"\nArguments:\n"
137-
"1. amount (numeric, required) The transaction fee in btc rounded to the nearest 0.00000001\n"
138-
"\nResult\n"
139-
"true|false (boolean) Returns true if successful\n"
140-
"\nExamples:\n"
141-
+ HelpExampleCli("settxfee", "0.00001")
142-
+ HelpExampleRpc("settxfee", "0.00001")
143-
);
144-
145-
// Amount
146-
int64_t nAmount = 0;
147-
if (params[0].get_real() != 0.0)
148-
nAmount = AmountFromValue(params[0]); // rejects 0.0 amounts
149-
150-
nTransactionFee = nAmount;
151-
return true;
152-
}
153-
154130
Value getrawmempool(const Array& params, bool fHelp)
155131
{
156132
if (fHelp || params.size() > 1)

0 commit comments

Comments
 (0)