aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2015-05-15 13:54:32 +0200
committerWladimir J. van der Laan <laanwj@gmail.com>2015-05-15 13:59:07 +0200
commite47c94e64c44e817ac80cf682a68ba0c4580952f (patch)
treeee2c59e0e8d3344673bcba76e2adeacec00b41a8 /src
parentf0043c2d6d2ceddd631a76b424dd8c163f3dad66 (diff)
parentf13dac972c9cf308abf72a1d1a54135b1392eaea (diff)
Merge pull request #6135
f13dac9 Comment edits and cleanup (BitcoinPRReadingGroup) ff734e9 Alphabetic order in makefile (Jorge Timón) 5207f33 fix header include groups (Philip Kaufmann) 59b149f remove unneeded incude of wallet/db.h from rpcmining.cpp (Philip Kaufmann) 3703385 remove unused classes from db.h (Philip Kaufmann) 0a7bcb7 fix IDE/compiler warning "extra ';'" in validationinterface.h (Philip Kaufmann) 3b00e7c [Trivial] Update COPYING (sandakersmann) dd9e688 Trivial: Corrected owner of DNS seeder (ayeowch) a60bfd8 [init] better message when no wallet support is compiled in (Philip Kaufmann) 78f44b6 Capitalized P2P (sandakersmann) 8e9248d [Trivial] Cryptocurrency is one word (sandakersmann) 803f51e Typo in GetRawMemPool RPC method help: "]" --> "}" (Chris Arnesen) 605a735 addrman: update comments (Pavel Vasin)
Diffstat (limited to 'src')
-rw-r--r--src/Makefile.am48
-rw-r--r--src/addrman.h8
-rw-r--r--src/chainparams.cpp2
-rw-r--r--src/init.cpp2
-rw-r--r--src/rpcblockchain.cpp2
-rw-r--r--src/rpcmining.cpp1
-rw-r--r--src/script/script.h3
-rw-r--r--src/serialize.h4
-rw-r--r--src/util.cpp10
-rw-r--r--src/validationinterface.h14
-rw-r--r--src/wallet/db.h3
11 files changed, 46 insertions, 51 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 91d530222f..93ad26acf8 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -77,8 +77,8 @@ BITCOIN_CORE_H = \
base58.h \
bloom.h \
chain.h \
- chainparamsbase.h \
chainparams.h \
+ chainparamsbase.h \
chainparamsseeds.h \
checkpoints.h \
checkqueue.h \
@@ -86,11 +86,13 @@ BITCOIN_CORE_H = \
coincontrol.h \
coins.h \
compat.h \
+ compat/byteswap.h \
+ compat/endian.h \
+ compat/sanity.h \
compressor.h \
consensus/consensus.h \
consensus/params.h \
core_io.h \
- wallet/db.h \
eccryptoverify.h \
ecwrapper.h \
hash.h \
@@ -104,8 +106,8 @@ BITCOIN_CORE_H = \
merkleblock.h \
miner.h \
mruset.h \
- netbase.h \
net.h \
+ netbase.h \
noui.h \
policy/fees.h \
pow.h \
@@ -119,8 +121,8 @@ BITCOIN_CORE_H = \
rpcserver.h \
scheduler.h \
script/interpreter.h \
- script/script_error.h \
script/script.h \
+ script/script_error.h \
script/sigcache.h \
script/sign.h \
script/standard.h \
@@ -146,12 +148,10 @@ BITCOIN_CORE_H = \
validationinterface.h \
version.h \
wallet/crypter.h \
- wallet/walletdb.h \
+ wallet/db.h \
wallet/wallet.h \
wallet/wallet_ismine.h \
- compat/byteswap.h \
- compat/endian.h \
- compat/sanity.h
+ wallet/walletdb.h
JSON_H = \
json/json_spirit.h \
@@ -218,39 +218,37 @@ libbitcoin_wallet_a_SOURCES = \
# crypto primitives library
crypto_libbitcoin_crypto_a_CPPFLAGS = $(BITCOIN_CONFIG_INCLUDES)
crypto_libbitcoin_crypto_a_SOURCES = \
- crypto/sha1.cpp \
- crypto/sha256.cpp \
- crypto/sha512.cpp \
- crypto/hmac_sha256.cpp \
- crypto/hmac_sha512.cpp \
- crypto/ripemd160.cpp \
crypto/common.h \
- crypto/sha256.h \
- crypto/sha512.h \
+ crypto/hmac_sha256.cpp \
crypto/hmac_sha256.h \
+ crypto/hmac_sha512.cpp \
crypto/hmac_sha512.h \
+ crypto/ripemd160.cpp \
+ crypto/ripemd160.h \
+ crypto/sha1.cpp \
crypto/sha1.h \
- crypto/ripemd160.h
+ crypto/sha256.cpp \
+ crypto/sha256.h \
+ crypto/sha512.cpp \
+ crypto/sha512.h
# univalue JSON library
univalue_libbitcoin_univalue_a_SOURCES = \
univalue/univalue.cpp \
- univalue/univalue_read.cpp \
- univalue/univalue_write.cpp \
+ univalue/univalue.h \
univalue/univalue_escapes.h \
- univalue/univalue.h
+ univalue/univalue_read.cpp \
+ univalue/univalue_write.cpp
# common: shared between bitcoind, and bitcoin-qt and non-server tools
libbitcoin_common_a_CPPFLAGS = $(BITCOIN_INCLUDES)
libbitcoin_common_a_SOURCES = \
- arith_uint256.cpp \
amount.cpp \
+ arith_uint256.cpp \
base58.cpp \
chainparams.cpp \
coins.cpp \
compressor.cpp \
- primitives/block.cpp \
- primitives/transaction.cpp \
core_read.cpp \
core_write.cpp \
eccryptoverify.cpp \
@@ -259,14 +257,16 @@ libbitcoin_common_a_SOURCES = \
key.cpp \
keystore.cpp \
netbase.cpp \
+ primitives/block.cpp \
+ primitives/transaction.cpp \
protocol.cpp \
pubkey.cpp \
scheduler.cpp \
script/interpreter.cpp \
script/script.cpp \
+ script/script_error.cpp \
script/sign.cpp \
script/standard.cpp \
- script/script_error.cpp \
$(BITCOIN_CORE_H)
# util: shared between all executables.
diff --git a/src/addrman.h b/src/addrman.h
index b72dda49d1..373b0f39f3 100644
--- a/src/addrman.h
+++ b/src/addrman.h
@@ -110,10 +110,10 @@ public:
*
* To that end:
* * Addresses are organized into buckets.
- * * Address that have not yet been tried go into 1024 "new" buckets.
- * * Based on the address range (/16 for IPv4) of source of the information, 64 buckets are selected at random
+ * * Addresses that have not yet been tried go into 1024 "new" buckets.
+ * * Based on the address range (/16 for IPv4) of the source of information, 64 buckets are selected at random.
* * The actual bucket is chosen from one of these, based on the range in which the address itself is located.
- * * One single address can occur in up to 8 different buckets, to increase selection chances for addresses that
+ * * One single address can occur in up to 8 different buckets to increase selection chances for addresses that
* are seen frequently. The chance for increasing this multiplicity decreases exponentially.
* * When adding a new address to a full bucket, a randomly chosen entry (with a bias favoring less recently seen
* ones) is removed from it first.
@@ -231,7 +231,6 @@ protected:
void Attempt_(const CService &addr, int64_t nTime);
//! Select an address to connect to.
- //! nUnkBias determines how much to favor new addresses over tried ones (min=0, max=100)
CAddrInfo Select_();
#ifdef DEBUG_ADDRMAN
@@ -532,7 +531,6 @@ public:
/**
* Choose an address to connect to.
- * nUnkBias determines how much "new" entries are favored over "tried" ones (0-100).
*/
CAddrInfo Select()
{
diff --git a/src/chainparams.cpp b/src/chainparams.cpp
index 556d0aed4d..5f400b265c 100644
--- a/src/chainparams.cpp
+++ b/src/chainparams.cpp
@@ -86,7 +86,7 @@ public:
vSeeds.push_back(CDNSSeedData("bitcoin.sipa.be", "seed.bitcoin.sipa.be")); // Pieter Wuille
vSeeds.push_back(CDNSSeedData("bluematt.me", "dnsseed.bluematt.me")); // Matt Corallo
vSeeds.push_back(CDNSSeedData("dashjr.org", "dnsseed.bitcoin.dashjr.org")); // Luke Dashjr
- vSeeds.push_back(CDNSSeedData("bitcoinstats.com", "seed.bitcoinstats.com")); // Addy Yeow
+ vSeeds.push_back(CDNSSeedData("bitcoinstats.com", "seed.bitcoinstats.com")); // Christian Decker
vSeeds.push_back(CDNSSeedData("xf2.org", "bitseed.xf2.org")); // Jeff Garzik
vSeeds.push_back(CDNSSeedData("bitcoin.jonasschnelli.ch", "seed.bitcoin.jonasschnelli.ch")); // Jonas Schnelli
diff --git a/src/init.cpp b/src/init.cpp
index 2d75850253..3c3b3fb231 100644
--- a/src/init.cpp
+++ b/src/init.cpp
@@ -1335,7 +1335,7 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
pwalletMain->SetBroadcastTransactions(GetBoolArg("-walletbroadcast", true));
} // (!fDisableWallet)
#else // ENABLE_WALLET
- LogPrintf("No wallet compiled in!\n");
+ LogPrintf("No wallet support compiled in!\n");
#endif // !ENABLE_WALLET
// ********************************************************* Step 9: import blocks
diff --git a/src/rpcblockchain.cpp b/src/rpcblockchain.cpp
index ecf8e8bcc6..4315c5ec18 100644
--- a/src/rpcblockchain.cpp
+++ b/src/rpcblockchain.cpp
@@ -170,7 +170,7 @@ Value getrawmempool(const Array& params, bool fHelp)
" \"transactionid\", (string) parent transaction id\n"
" ... ]\n"
" }, ...\n"
- "]\n"
+ "}\n"
"\nExamples\n"
+ HelpExampleCli("getrawmempool", "true")
+ HelpExampleRpc("getrawmempool", "true")
diff --git a/src/rpcmining.cpp b/src/rpcmining.cpp
index 24b865150a..a6a8b9422f 100644
--- a/src/rpcmining.cpp
+++ b/src/rpcmining.cpp
@@ -16,7 +16,6 @@
#include "util.h"
#include "validationinterface.h"
#ifdef ENABLE_WALLET
-#include "wallet/db.h"
#include "wallet/wallet.h"
#endif
diff --git a/src/script/script.h b/src/script/script.h
index ed456f5c5a..d5045005be 100644
--- a/src/script/script.h
+++ b/src/script/script.h
@@ -6,6 +6,8 @@
#ifndef BITCOIN_SCRIPT_SCRIPT_H
#define BITCOIN_SCRIPT_SCRIPT_H
+#include "crypto/common.h"
+
#include <assert.h>
#include <climits>
#include <limits>
@@ -14,7 +16,6 @@
#include <string.h>
#include <string>
#include <vector>
-#include "crypto/common.h"
static const unsigned int MAX_SCRIPT_ELEMENT_SIZE = 520; // bytes
diff --git a/src/serialize.h b/src/serialize.h
index 741f78f8b4..53d8af142f 100644
--- a/src/serialize.h
+++ b/src/serialize.h
@@ -6,6 +6,8 @@
#ifndef BITCOIN_SERIALIZE_H
#define BITCOIN_SERIALIZE_H
+#include "compat/endian.h"
+
#include <algorithm>
#include <assert.h>
#include <ios>
@@ -18,8 +20,6 @@
#include <utility>
#include <vector>
-#include "compat/endian.h"
-
class CScript;
static const unsigned int MAX_SIZE = 0x02000000;
diff --git a/src/util.cpp b/src/util.cpp
index da5b259aee..bfb95c9044 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -7,11 +7,6 @@
#include "config/bitcoin-config.h"
#endif
-#if (defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__DragonFly__))
-#include <pthread.h>
-#include <pthread_np.h>
-#endif
-
#include "util.h"
#include "chainparamsbase.h"
@@ -23,6 +18,11 @@
#include <stdarg.h>
+#if (defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__DragonFly__))
+#include <pthread.h>
+#include <pthread_np.h>
+#endif
+
#ifndef WIN32
// for posix_fallocate
#ifdef __linux__
diff --git a/src/validationinterface.h b/src/validationinterface.h
index b4c93d72ca..2a4c7ecceb 100644
--- a/src/validationinterface.h
+++ b/src/validationinterface.h
@@ -28,13 +28,13 @@ void SyncWithWallets(const CTransaction& tx, const CBlock* pblock = NULL);
class CValidationInterface {
protected:
- virtual void SyncTransaction(const CTransaction &tx, const CBlock *pblock) {};
- virtual void EraseFromWallet(const uint256 &hash) {};
- virtual void SetBestChain(const CBlockLocator &locator) {};
- virtual void UpdatedTransaction(const uint256 &hash) {};
- virtual void Inventory(const uint256 &hash) {};
- virtual void ResendWalletTransactions(int64_t nBestBlockTime) {};
- virtual void BlockChecked(const CBlock&, const CValidationState&) {};
+ virtual void SyncTransaction(const CTransaction &tx, const CBlock *pblock) {}
+ virtual void EraseFromWallet(const uint256 &hash) {}
+ virtual void SetBestChain(const CBlockLocator &locator) {}
+ virtual void UpdatedTransaction(const uint256 &hash) {}
+ virtual void Inventory(const uint256 &hash) {}
+ virtual void ResendWalletTransactions(int64_t nBestBlockTime) {}
+ virtual void BlockChecked(const CBlock&, const CValidationState&) {}
friend void ::RegisterValidationInterface(CValidationInterface*);
friend void ::UnregisterValidationInterface(CValidationInterface*);
friend void ::UnregisterAllValidationInterfaces();
diff --git a/src/wallet/db.h b/src/wallet/db.h
index 9596723b21..2df6f6e5a9 100644
--- a/src/wallet/db.h
+++ b/src/wallet/db.h
@@ -20,9 +20,6 @@
#include <db_cxx.h>
-class CDiskBlockIndex;
-class COutPoint;
-
extern unsigned int nWalletDBUpdated;
class CDBEnv