Browse Source

Merge pull request #4911

611116d header include cleanup (Philip Kaufmann)
pull/145/head
Pieter Wuille 10 years ago
parent
commit
7388b74cd2
No known key found for this signature in database GPG Key ID: 8F653255C87992E0
  1. 6
      src/Makefile.am
  2. 1
      src/allocators.h
  3. 4
      src/bitcoin-cli.cpp
  4. 13
      src/bitcoin-tx.cpp
  5. 2
      src/chainparamsbase.h
  6. 2
      src/core_io.h
  7. 11
      src/core_read.cpp
  8. 7
      src/core_write.cpp
  9. 1
      src/crypto/ripemd160.cpp
  10. 1
      src/crypto/sha1.cpp
  11. 1
      src/crypto/sha2.cpp
  12. 1
      src/db.cpp
  13. 4
      src/db.h
  14. 2
      src/hash.h
  15. 2
      src/init.cpp
  16. 1
      src/leveldbwrapper.h
  17. 2
      src/net.cpp
  18. 2
      src/pow.h
  19. 4
      src/random.cpp
  20. 2
      src/rpcclient.cpp
  21. 3
      src/rpcdump.cpp
  22. 4
      src/rpcmining.cpp
  23. 1
      src/rpcnet.cpp
  24. 2
      src/rpcprotocol.cpp
  25. 4
      src/rpcrawtransaction.cpp
  26. 2
      src/serialize.h
  27. 3
      src/sync.cpp
  28. 4
      src/timedata.h
  29. 3
      src/txdb.cpp
  30. 4
      src/txmempool.cpp
  31. 2
      src/uint256.h
  32. 2
      src/util.h
  33. 3
      src/utilstrencodings.cpp
  34. 1
      src/version.cpp
  35. 2
      src/wallet.h
  36. 2
      src/walletdb.cpp

6
src/Makefile.am

@ -103,7 +103,6 @@ BITCOIN_CORE_H = \
script/script.h \
script/sign.h \
script/standard.h \
wallet_ismine.h \
serialize.h \
sync.h \
threadsafety.h \
@ -118,8 +117,9 @@ BITCOIN_CORE_H = \
utilmoneystr.h \
utiltime.h \
version.h \
walletdb.h \
wallet.h \
wallet_ismine.h \
walletdb.h \
compat/sanity.h
JSON_H = \
@ -173,8 +173,8 @@ libbitcoin_wallet_a_SOURCES = \
crypter.cpp \
rpcdump.cpp \
rpcwallet.cpp \
wallet_ismine.cpp \
wallet.cpp \
wallet_ismine.cpp \
walletdb.cpp \
$(BITCOIN_CORE_H)

1
src/allocators.h

@ -12,6 +12,7 @@
#include <boost/thread/mutex.hpp>
#include <boost/thread/once.hpp>
#include <openssl/crypto.h> // for OPENSSL_cleanse()
/**

4
src/bitcoin-cli.cpp

@ -3,11 +3,11 @@
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "util.h"
#include "chainparamsbase.h"
#include "init.h"
#include "rpcclient.h"
#include "rpcprotocol.h"
#include "chainparamsbase.h"
#include "util.h"
#include "utilstrencodings.h"
#include "version.h"

13
src/bitcoin-tx.cpp

@ -3,23 +3,24 @@
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "base58.h"
#include "util.h"
#include "utilmoneystr.h"
#include "core.h"
#include "main.h" // for MAX_BLOCK_SIZE
#include "core_io.h"
#include "keystore.h"
#include "main.h" // for MAX_BLOCK_SIZE
#include "script/script.h"
#include "script/sign.h"
#include "ui_interface.h" // for _(...)
#include "univalue/univalue.h"
#include "core_io.h"
#include "util.h"
#include "utilmoneystr.h"
#include <stdio.h>
#include <boost/assign/list_of.hpp>
#include <boost/algorithm/string.hpp>
#include <boost/assign/list_of.hpp>
using namespace std;
using namespace boost::assign;
using namespace std;
static bool fCreateBlank;
static map<string,UniValue> registers;

2
src/chainparamsbase.h

@ -5,8 +5,8 @@
#ifndef BITCOIN_CHAIN_PARAMS_BASE_H
#define BITCOIN_CHAIN_PARAMS_BASE_H
#include <vector>
#include <string>
#include <vector>
/**
* CBaseChainParams defines the base parameters (shared between bitcoin-cli and bitcoind)

2
src/core_io.h

@ -8,9 +8,9 @@
#include <string>
#include <vector>
class uint256;
class CScript;
class CTransaction;
class uint256;
class UniValue;
// core_read.cpp

11
src/core_read.cpp

@ -3,21 +3,22 @@
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "core_io.h"
#include "core.h"
#include "serialize.h"
#include "script/script.h"
#include "serialize.h"
#include "univalue/univalue.h"
#include "util.h"
#include <boost/assign/list_of.hpp>
#include <boost/algorithm/string/classification.hpp>
#include <boost/algorithm/string/predicate.hpp>
#include <boost/algorithm/string/split.hpp>
#include <boost/algorithm/string/replace.hpp>
#include "univalue/univalue.h"
#include <boost/algorithm/string/split.hpp>
#include <boost/assign/list_of.hpp>
using namespace std;
using namespace boost;
using namespace boost::algorithm;
using namespace std;
CScript ParseScript(std::string s)
{

7
src/core_write.cpp

@ -3,14 +3,15 @@
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "core_io.h"
#include "univalue/univalue.h"
#include "base58.h"
#include "core.h"
#include "script/script.h"
#include "script/standard.h"
#include "core.h"
#include "serialize.h"
#include "univalue/univalue.h"
#include "util.h"
#include "utilmoneystr.h"
#include "base58.h"
#include <boost/foreach.hpp>

1
src/crypto/ripemd160.cpp

@ -5,6 +5,7 @@
#include "crypto/ripemd160.h"
#include "crypto/common.h"
#include <string.h>
// Internal implementation code.

1
src/crypto/sha1.cpp

@ -5,6 +5,7 @@
#include "crypto/sha1.h"
#include "crypto/common.h"
#include <string.h>
// Internal implementation code.

1
src/crypto/sha2.cpp

@ -5,6 +5,7 @@
#include "crypto/sha2.h"
#include "crypto/common.h"
#include <string.h>
// Internal implementation code.

1
src/db.cpp

@ -20,6 +20,7 @@
#include <boost/filesystem.hpp>
#include <boost/thread.hpp>
#include <boost/version.hpp>
#include <openssl/rand.h>
using namespace std;

4
src/db.h

@ -15,12 +15,14 @@
#include <vector>
#include <boost/filesystem/path.hpp>
#include <db_cxx.h>
struct CBlockLocator;
class CDiskBlockIndex;
class COutPoint;
struct CBlockLocator;
extern unsigned int nWalletDBUpdated;
void ThreadFlushWalletDB(const std::string& strWalletFile);

2
src/hash.h

@ -6,8 +6,8 @@
#ifndef BITCOIN_HASH_H
#define BITCOIN_HASH_H
#include "crypto/sha2.h"
#include "crypto/ripemd160.h"
#include "crypto/sha2.h"
#include "serialize.h"
#include "uint256.h"
#include "version.h"

2
src/init.cpp

@ -11,6 +11,7 @@
#include "addrman.h"
#include "checkpoints.h"
#include "compat/sanity.h"
#include "key.h"
#include "main.h"
#include "miner.h"
@ -32,7 +33,6 @@
#ifndef WIN32
#include <signal.h>
#endif
#include "compat/sanity.h"
#include <boost/algorithm/string/predicate.hpp>
#include <boost/algorithm/string/replace.hpp>

1
src/leveldbwrapper.h

@ -10,6 +10,7 @@
#include "version.h"
#include <boost/filesystem/path.hpp>
#include <leveldb/db.h>
#include <leveldb/write_batch.h>

2
src/net.cpp

@ -48,8 +48,8 @@
#endif
#endif
using namespace std;
using namespace boost;
using namespace std;
namespace {
const int MAX_OUTBOUND_CONNECTIONS = 8;

2
src/pow.h

@ -8,8 +8,8 @@
#include <stdint.h>
class CBlockIndex;
class CBlockHeader;
class CBlockIndex;
class uint256;
unsigned int GetNextWorkRequired(const CBlockIndex* pindexLast, const CBlockHeader *pblock);

4
src/random.cpp

@ -12,10 +12,12 @@
#include "util.h" // for LogPrint()
#include "utilstrencodings.h" // for GetTime()
#include <limits>
#ifndef WIN32
#include <sys/time.h>
#endif
#include <limits>
#include <openssl/crypto.h>
#include <openssl/err.h>
#include <openssl/rand.h>

2
src/rpcclient.cpp

@ -3,7 +3,6 @@
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <set>
#include "rpcclient.h"
#include "rpcprotocol.h"
@ -11,6 +10,7 @@
#include "ui_interface.h"
#include "chainparams.h" // for Params().RPCPort()
#include <set>
#include <stdint.h>
using namespace std;

3
src/rpcdump.cpp

@ -7,8 +7,8 @@
#include "init.h"
#include "main.h"
#include "sync.h"
#include "utiltime.h"
#include "util.h"
#include "utiltime.h"
#include "wallet.h"
#include <fstream>
@ -16,6 +16,7 @@
#include <boost/algorithm/string.hpp>
#include <boost/date_time/posix_time/posix_time.hpp>
#include "json/json_spirit_value.h"
using namespace json_spirit;

4
src/rpcmining.cpp

@ -3,14 +3,14 @@
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "rpcserver.h"
#include "chainparams.h"
#include "core_io.h"
#include "init.h"
#include "net.h"
#include "main.h"
#include "miner.h"
#include "pow.h"
#include "core_io.h"
#include "rpcserver.h"
#include "util.h"
#ifdef ENABLE_WALLET
#include "db.h"

1
src/rpcnet.cpp

@ -13,6 +13,7 @@
#include "util.h"
#include <boost/foreach.hpp>
#include "json/json_spirit_value.h"
using namespace json_spirit;

2
src/rpcprotocol.cpp

@ -5,8 +5,8 @@
#include "rpcprotocol.h"
#include "util.h"
#include "tinyformat.h"
#include "util.h"
#include "utilstrencodings.h"
#include "utiltime.h"
#include "version.h"

4
src/rpcrawtransaction.cpp

@ -12,8 +12,8 @@
#include "net.h"
#include "rpcserver.h"
#include "script/script.h"
#include "script/standard.h"
#include "script/sign.h"
#include "script/standard.h"
#include "uint256.h"
#ifdef ENABLE_WALLET
#include "wallet.h"
@ -25,10 +25,10 @@
#include "json/json_spirit_utils.h"
#include "json/json_spirit_value.h"
using namespace std;
using namespace boost;
using namespace boost::assign;
using namespace json_spirit;
using namespace std;
void ScriptPubKeyToJSON(const CScript& scriptPubKey, Object& out, bool fIncludeHex)
{

2
src/serialize.h

@ -10,8 +10,8 @@
#include <algorithm>
#include <assert.h>
#include <limits>
#include <ios>
#include <limits>
#include <map>
#include <set>
#include <stdint.h>

3
src/sync.cpp

@ -7,9 +7,10 @@
#include "util.h"
#include "utilstrencodings.h"
#include <stdio.h>
#include <boost/foreach.hpp>
#include <boost/thread.hpp>
#include <stdio.h>
#ifdef DEBUG_LOCKCONTENTION
void PrintLockContention(const char* pszName, const char* pszFile, int nLine)

4
src/timedata.h

@ -5,10 +5,10 @@
#ifndef BITCOIN_TIMEDATA_H
#define BITCOIN_TIMEDATA_H
#include <stdint.h>
#include <vector>
#include <algorithm>
#include <assert.h>
#include <stdint.h>
#include <vector>
class CNetAddr;

3
src/txdb.cpp

@ -9,9 +9,10 @@
#include "pow.h"
#include "uint256.h"
#include <boost/thread.hpp>
#include <stdint.h>
#include <boost/thread.hpp>
using namespace std;
void static BatchWriteCoins(CLevelDBBatch &batch, const uint256 &hash, const CCoins &coins) {

4
src/txmempool.cpp

@ -3,8 +3,9 @@
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "core.h"
#include "txmempool.h"
#include "core.h"
#include "util.h"
#include <boost/circular_buffer.hpp>
@ -646,4 +647,3 @@ bool CCoinsViewMemPool::GetCoins(const uint256 &txid, CCoins &coins) const {
bool CCoinsViewMemPool::HaveCoins(const uint256 &txid) const {
return mempool.exists(txid) || base->HaveCoins(txid);
}

2
src/uint256.h

@ -7,10 +7,10 @@
#define BITCOIN_UINT256_H
#include <assert.h>
#include <cstring>
#include <stdexcept>
#include <stdint.h>
#include <string>
#include <cstring>
#include <vector>
class uint_error : public std::runtime_error {

2
src/util.h

@ -15,8 +15,8 @@
#endif
#include "compat.h"
#include "utiltime.h"
#include "tinyformat.h"
#include "utiltime.h"
#include <exception>
#include <map>

3
src/utilstrencodings.cpp

@ -7,10 +7,11 @@
#include "tinyformat.h"
#include <boost/foreach.hpp>
#include <errno.h>
#include <limits>
#include <boost/foreach.hpp>
using namespace std;
// safeChars chosen to allow simple messages/URLs/email addresses, but avoid anything

1
src/version.cpp

@ -7,6 +7,7 @@
#include "tinyformat.h"
#include <string>
#include <boost/algorithm/string/join.hpp>
// Name of client reported in the 'version' message. Report the same name

2
src/wallet.h

@ -11,8 +11,8 @@
#include "key.h"
#include "keystore.h"
#include "main.h"
#include "wallet_ismine.h"
#include "ui_interface.h"
#include "wallet_ismine.h"
#include "walletdb.h"
#include <algorithm>

2
src/walletdb.cpp

@ -9,8 +9,8 @@
#include "protocol.h"
#include "serialize.h"
#include "sync.h"
#include "utiltime.h"
#include "util.h"
#include "utiltime.h"
#include "wallet.h"
#include <boost/filesystem.hpp>

Loading…
Cancel
Save