From de76d6c98f8282f234528fd40e559d6564c13861 Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Mon, 21 May 2012 14:33:44 -0700 Subject: [PATCH] Use the new code. --- src/Config.h | 56 +++++++++++++++++++++++------------------------ src/RPCServer.cpp | 2 +- 2 files changed, 29 insertions(+), 29 deletions(-) diff --git a/src/Config.h b/src/Config.h index c5aadc6091..4eb84dc279 100644 --- a/src/Config.h +++ b/src/Config.h @@ -6,12 +6,12 @@ #include -#define SYSTEM_NAME "newcoin" -#define VALIDATORS_SITE "redstem.com" -#define SYSTEM_CURRENCY_CODE "XNS" -#define SYSTEM_CURRENCY_PRECISION 6 +#define SYSTEM_NAME "newcoin" +#define VALIDATORS_SITE "redstem.com" +#define SYSTEM_CURRENCY_CODE "XNS" +#define SYSTEM_CURRENCY_PRECISION 6 -#define VALIDATORS_FILE_NAME "validators.txt" +#define VALIDATORS_FILE_NAME "validators.txt" const int SYSTEM_PEER_PORT = 6561; // Allow anonymous DH. @@ -21,7 +21,7 @@ const int SYSTEM_PEER_PORT = 6561; #define DEFAULT_PEER_SCAN_INTERVAL_MIN (60*60) // Maximum number of peers to try to connect to as client at once. -#define DEFAULT_PEER_START_MAX 5 +#define DEFAULT_PEER_START_MAX 5 // Might connect with fewer for testing. #define DEFAULT_PEER_CONNECT_LOW_WATER 4 @@ -30,28 +30,28 @@ class Config { public: // Core software parameters - int VERSION; - std::string VERSION_STR; + int VERSION; + std::string VERSION_STR; // Network parameters - int NETWORK_START_TIME; // The Unix time we start ledger 0 - int TRANSACTION_FEE_BASE; - int LEDGER_SECONDS; - int LEDGER_PROPOSAL_DELAY_SECONDS; - int LEDGER_AVALANCHE_SECONDS; + int NETWORK_START_TIME; // The Unix time we start ledger 0 + int TRANSACTION_FEE_BASE; + int LEDGER_SECONDS; + int LEDGER_PROPOSAL_DELAY_SECONDS; + int LEDGER_AVALANCHE_SECONDS; // Note: The following parameters do not relate to the UNL or trust at all - int NETWORK_QUORUM; // Minimum number of nodes to consider the network present - int VALIDATION_QUORUM; // Minimum validations to consider ledger authoritative + int NETWORK_QUORUM; // Minimum number of nodes to consider the network present + int VALIDATION_QUORUM; // Minimum validations to consider ledger authoritative // Peer networking parameters std::string PEER_IP; - int PEER_PORT; - int NUMBER_CONNECTIONS; + int PEER_PORT; + int NUMBER_CONNECTIONS; std::string PEER_SSL_CIPHER_LIST; - int PEER_SCAN_INTERVAL_MIN; - int PEER_START_MAX; - int PEER_CONNECT_LOW_WATER; + int PEER_SCAN_INTERVAL_MIN; + int PEER_START_MAX; + int PEER_CONNECT_LOW_WATER; // bool NODE_INBOUND; // We accept inbound connections // bool NODE_DATABASE; // We offer historical data services @@ -60,18 +60,18 @@ public: // bool NODE_SMART; // We offer services to 'dumb' clients // RPC parameters - std::string RPC_IP; - int RPC_PORT; - std::string RPC_USER; - std::string RPC_PASSWORD; + std::string RPC_IP; + int RPC_PORT; + std::string RPC_USER; + std::string RPC_PASSWORD; // Validation - std::string VALIDATION_PASSWORD; - std::string VALIDATION_KEY; + std::string VALIDATION_PASSWORD; + std::string VALIDATION_KEY; // Fees - STAmount FEE_CREATE; // Fee to create an account - STAmount FEE_DEFAULT; // Default fee. + uint64 FEE_CREATE; // Fee to create an account + uint64 FEE_DEFAULT; // Default fee. // configuration parameters std::string DATA_DIR; diff --git a/src/RPCServer.cpp b/src/RPCServer.cpp index e036b5bd42..969fc7ab9e 100644 --- a/src/RPCServer.cpp +++ b/src/RPCServer.cpp @@ -743,7 +743,7 @@ Json::Value RPCServer::doWalletCreate(Json::Value& params) { return obj; } - else if (saSrcBalance < theConfig.FEE_CREATE + saInitialFunds) + else if (saSrcBalance < (saInitialFunds + theConfig.FEE_CREATE)) { return JSONRPCError(500, "insufficent funds"); }