aboutsummaryrefslogtreecommitdiff
path: root/src/main.h
AgeCommit message (Collapse)Author
2015-03-27Add a consistency check for the block chain data structuresPieter Wuille
This adds a -checkblockindex (defaulting to true for regtest), which occasionally does a full consistency check for mapBlockIndex, setBlockIndexCandidates, chainActive, and mapBlocksUnlinked.
2015-03-26don't trickle for whitelisted nodesRuben de Vries
Rebased-From: fc720207e0e513e531b1f266b966a2ffa57b936a Github-Pull: #5942
2014-12-22remove max orphan blocks config parameter since it is no longer functionalJameson Lopp
Rebased-From: 4bc95c43871645c1d69a0d719c13b38151a3a13f
2014-12-05Merge pull request #5181Wladimir J. van der Laan
afd4b94 Move CMerkleBlock and CPartialMerkleTree to their own file (Matt Corallo)
2014-12-05Move CMerkleBlock and CPartialMerkleTree to their own fileMatt Corallo
2014-12-04Merge pull request #5394Wladimir J. van der Laan
307f7d4 Report script evaluation failures in log and reject messages (Pieter Wuille)
2014-12-03Merge pull request #5306Wladimir J. van der Laan
d227011 MOVEONLY: core/ -> primitives/ (Luke Dashjr)
2014-12-03MOVEONLY: core/ -> primitives/Luke Dashjr
2014-12-02Report script evaluation failures in log and reject messagesPieter Wuille
2014-12-02Make comments in main an init doxygen compatibleMichael Ford
Fix typos where appropriate Update license/copyright
2014-11-28Merge pull request #5316Wladimir J. van der Laan
f86a24b Move `setmocktime` to hidden category (Wladimir J. van der Laan) bd9aebf Introduce a hidden category (Pieter Wuille) 0dd06b2 Delay writing block indexes in invalidate/reconsider (Pieter Wuille) 9b0a8d3 Add 'invalidateblock' and 'reconsiderblock' RPC commands. (Pieter Wuille)
2014-11-27Remove -printblock, -printblocktree, and -printblockindexPieter Wuille
2014-11-26Add 'invalidateblock' and 'reconsiderblock' RPC commands.Pieter Wuille
These can be used for testing reorganizations or for manual intervention in case of chain forks.
2014-11-24Improve chainstate/blockindex disk writing policyPieter Wuille
There are 3 pieces of data that are maintained on disk. The actual block and undo data, the block index (which can refer to positions on disk), and the chainstate (which refers to the best block hash). Earlier, there was no guarantee that blocks were written to disk before block index entries referring to them were written. This commit introduces dirty flags for block index data, and delays writing entries until the actual block data is flushed. With this stricter ordering in writes, it is now safe to not always flush after every block, so there is no need for the IsInitialBlockDownload() check there - instead we just write whenever enough time has passed or the cache size grows too large. Also updating the wallet's best known block is delayed until this is done, otherwise the wallet may end up referring to an unknown block. In addition, only do a write inside the block processing loop if necessary (because of cache size exceeded). Otherwise, move the writing to a point after processing is done, after relaying.
2014-11-18TestBlockValidity function for CBlock proposals (used by CreateNewBlock)Luke Dashjr
2014-11-18Abstract context-dependent block checking from acceptanceLuke Dashjr
2014-11-03Merge pull request #5186Wladimir J. van der Laan
771d500 minor cleanup: include orders, end comments etc. (Philip Kaufmann)
2014-11-03Merge pull request #5106Wladimir J. van der Laan
1bea2bb Rename ProcessBlock to ProcessNewBlock to indicate change of behaviour, and document it (Luke Dashjr) d29a291 Rename RPC_TRANSACTION_* errors to RPC_VERIFY_* and use RPC_VERIFY_ERROR for submitblock (Luke Dashjr) f877aaa Bugfix: submitblock: Use a temporary CValidationState to determine accurately the outcome of ProcessBlock, now that it no longer does the full block validity check (Luke Dashjr) 24e8896 Add CValidationInterface::BlockChecked notification (Luke Dashjr)
2014-10-31minor cleanup: include orders, end comments etc.Philip Kaufmann
- no code changes
2014-10-28Rename ProcessBlock to ProcessNewBlock to indicate change of behaviour, and ↵Luke Dashjr
document it
2014-10-27MOVEONLY: core.o -> core/block.ojtimon
2014-10-27MOVEONLY: separate CTxUndo out of corejtimon
2014-10-27MOVEONLY: Separate CTransaction and dependencies from corejtimon
2014-10-27MOVEONLY: Move CFeeRate and Amount constants to amount.ojtimon
2014-10-22Merge pull request #4981Wladimir J. van der Laan
85c579e script: add a slew of includes all around and drop includes from script.h (Cory Fields) db8eb54 script: move ToString and ValueString out of the header (Cory Fields) e9ca428 script: add ToByteVector() for converting anything with begin/end (Cory Fields) 066e2a1 script: move CScriptID to standard.h and add a ctor for creating them from CScripts (Cory Fields)
2014-10-21Add CValidationInterface::BlockChecked notificationLuke Dashjr
2014-10-20Rename CWalletInterface to CValidationInterfacePieter Wuille
It's useful for much more than wallets.
2014-10-17script: add a slew of includes all around and drop includes from script.hCory Fields
Lots of files ended up with indirect includes from script.h.
2014-10-14RPC additions after headers-firstPieter Wuille
2014-10-14Headers-first synchronizationPieter Wuille
Many changes: * Do not use 'getblocks', but 'getheaders', and use it to build a headers tree. * Blocks are fetched in parallel from all available outbound peers, using a limited moving window. When one peer stalls the movement of the window, it is disconnected. * No more orphan blocks. At all. We only ever request a block for which we have verified the headers, and store it to disk immediately. This means that a disk-fill attack would require PoW. * Require protocol version 31800 for every peer (released in december 2010). * No more syncnode (we sync from everyone we can, though limited to 1 during initial *headers* sync). * Introduce some extra named constants, comments and asserts.
2014-10-06Merge pull request #5036Wladimir J. van der Laan
eb6b3b2 Update English translation (Wladimir J. van der Laan) b9b2e3f Don't translate state.Abort() messages (Wladimir J. van der Laan)
2014-10-02Don't translate state.Abort() messagesWladimir J. van der Laan
There is only one message passed to AbortNode() that makes sense to translate to the user specifically: Disk space is low. For the others show a generic message and refer to debug.log for details. Reduces the number of confusing jargon translation messages.
2014-10-02Replace SCRIPT_VERIFY_NOCACHE by flag directly to checkerPieter Wuille
2014-10-02Make signature cache optionalPieter Wuille
2014-10-01Merge pull request #4234Wladimir J. van der Laan
c122f55 qt: Register CAmount metatype (Wladimir J. van der Laan) a372168 Use a typedef for monetary values (Mark Friedenbach)
2014-09-29Merge pull request #4796Pieter Wuille
e8b5f0d Move CBlockIndex, CChain and related code out of main (jtimon) 6db83db Decouple CChain from mapBlockIndex (jtimon)
2014-09-26Use a typedef for monetary valuesMark Friedenbach
2014-09-17Merge pull request #4555Wladimir J. van der Laan
6dcfda2 Don't pass nHashType to EvalScript nor CheckSig (jtimon) 2b23a87 Don't pass nHashType to VerifyScript (jtimon) ce3649fb Remove CScriptCheck::nHashType (was always 0) (jtimon) 358562b Remove unused function main:VerifySignature (jtimon)
2014-09-16Merge pull request #4875Pieter Wuille
f7e3637 Eliminate extra assignment (Suhas Daftuar) ec7eb0f When reindexing check for file before trying to open (refactored) (Suhas Daftuar)
2014-09-12Remove CScriptCheck::nHashType (was always 0)jtimon
2014-09-12Remove unused function main:VerifySignaturejtimon
2014-09-10Store fewer orphan tx by default, add -maxorphantx optionGavin Andresen
There is no reason to store thousands of orphan transactions; normally an orphan's parents will either be broadcast or mined reasonably quickly. This pull drops the maximum number of orphans from 10,000 down to 100, and adds a command-line option (-maxorphantx) that is just like -maxorphanblocks to override the default.
2014-09-10When reindexing check for file before trying to open (refactored)Suhas Daftuar
2014-09-08Move CBlockIndex, CChain and related code out of mainjtimon
2014-09-08Decouple CChain from mapBlockIndexjtimon
2014-09-08Separate script/standardjtimon
2014-09-08Rename script.h/.cpp to scriptutils.h/.cpp (plus remove duplicated includes)jtimon
2014-09-04Use boost::unordered_map for mapBlockIndexPieter Wuille
2014-09-04Introduce BlockMap type for mapBlockIndexPieter Wuille
2014-09-03Merge pull request #4808Pieter Wuille
3f6540a Rename IMPLEMENT_SERIALIZE to ADD_SERIALIZE_METHODS (Pieter Wuille) 47eb765 Serializer simplifications after IMPLEMENT_SERIALIZE overhaul (Pieter Wuille)