aboutsummaryrefslogtreecommitdiff
path: root/src/protocol.h
Commit message (Collapse)AuthorAgeFilesLines
* Rename IMPLEMENT_SERIALIZE to ADD_SERIALIZE_METHODSPieter Wuille2014-09-021-3/+3
|
* Serializer simplifications after IMPLEMENT_SERIALIZE overhaulPieter Wuille2014-09-011-6/+3
|
* Use CSizeComputer to avoid counting sizes in SerializationOpPieter Wuille2014-08-311-13/+5
|
* rework overhauled serialization methods to non-staticKamil Domanski2014-08-311-18/+18
| | | | | | | Thanks to Pieter Wuille for most of the work on this commit. I did not fixup the overhaul commit, because a rebase conflicted with "remove fields of ser_streamplaceholder". I prefer not to risk making a mistake while resolving it.
* overhaul serialization codeKamil Domanski2014-08-311-23/+38
| | | | | | | | | | | | | | | | | | | | | The implementation of each class' serialization/deserialization is no longer passed within a macro. The implementation now lies within a template of form: template <typename T, typename Stream, typename Operation> inline static size_t SerializationOp(T thisPtr, Stream& s, Operation ser_action, int nType, int nVersion) { size_t nSerSize = 0; /* CODE */ return nSerSize; } In cases when codepath should depend on whether or not we are just deserializing (old fGetSize, fWrite, fRead flags) an additional clause can be used: bool fRead = boost::is_same<Operation, CSerActionUnserialize>(); The IMPLEMENT_SERIALIZE macro will now be a freestanding clause added within class' body (similiar to Qt's Q_OBJECT) to implement GetSerializeSize, Serialize and Unserialize. These are now wrappers around the "SerializationOp" template.
* Revert "Add a getutxos command to the p2p protocol. It allows querying of ↵Wladimir J. van der Laan2014-08-271-1/+0
| | | | | | the UTXO set" This reverts commit da2ec100f3681176f60dec6dc675fc64147ade3a.
* Merge pull request #4351Wladimir J. van der Laan2014-08-251-0/+1
|\ | | | | | | da2ec10 Add a getutxos command to the p2p protocol. It allows querying of the UTXO set given a set of outpoints. (Mike Hearn)
| * Add a getutxos command to the p2p protocol. It allows querying of the UTXO setMike Hearn2014-08-111-0/+1
| | | | | | | | given a set of outpoints.
* | Remove all other print() methodsWladimir J. van der Laan2014-08-201-3/+0
|/ | | | All unused.
* Add comment regarding experimental-use service bitsPeter Todd2014-06-211-0/+8
| | | | As per mailing list discussion.
* Replace virtual methods with static attributes, chainparams.h depends onjtimon2014-06-041-1/+2
| | | | protocol.h instead of the other way around
* Reduce bignum.h now it is only needed for scriptnum_testsPieter Wuille2014-05-091-0/+1
|
* Cleanup code using forward declarations.Brandon Dahler2013-11-101-5/+7
| | | | | | | | | Use misc methods of avoiding unnecesary header includes. Replace int typedefs with int##_t from stdint.h. Replace PRI64[xdu] with PRI[xdu]64 from inttypes.h. Normalize QT_VERSION ifs where possible. Resolve some indirect dependencies as direct ones. Remove extern declarations from .cpp files.
* Bump Year Number to 2013super32013-10-201-1/+1
|
* Introduce a CChainParameters singleton class and regtest mode.Mike Hearn2013-06-191-10/+1
| | | | | | | | | | | | | The new class is accessed via the Params() method and holds most things that vary between main, test and regtest networks. The regtest mode has two purposes, one is to run the bitcoind/bitcoinj comparison tool which compares two separate implementations of the Bitcoin protocol looking for divergence. The other is that when run, you get a local node which can mine a single block instantly, which is highly convenient for testing apps during development as there's no need to wait 10 minutes for a block on the testnet.
* Use per-message send buffer, rather than per connectionPieter Wuille2013-03-291-1/+2
|
* Relay CMerkleBlocks when asked for MSG_FILTERED_BLOCKMatt Corallo2013-01-161-0/+3
|
* Abstract block hash substr extraction (for debug.log) into BlockHashStr inlineLuke Dashjr2012-11-131-0/+6
|
* Fix remaining warnings.Matt Corallo2012-07-041-2/+10
|
* Update License in File HeadersFordy2012-05-181-1/+1
| | | | | | I originally created a pull to replace the "COPYING" in crypter.cpp and crypter.h, but it turned out that COPYING was actually the correct file.
* Move proto version to version.h. Reduce header deps a bit more.Jeff Garzik2012-04-171-1/+0
|
* Replace several network protocol version numbers with named constantsJeff Garzik2012-04-121-3/+4
| | | | | | | stored in version.h. Also, a minor CAddress code reformat while we're in there, fixing some incorrect indentation.
* Begin doxygen-compatible commentsPieter Wuille2012-03-261-6/+9
|
* CAddrMan: stochastic address managerPieter Wuille2012-02-241-1/+1
| | | | | | | | | Design goals: * Only keep a limited number of addresses around, so that addr.dat does not grow without bound. * Keep the address tables in-memory, and occasionally write the table to addr.dat. * Make sure no (localized) attacker can fill the entire table with his nodes/addresses. See comments in addrman.h for more detailed information.
* Post-feb20 simplificationsPieter Wuille2012-02-211-1/+0
| | | | | Now the entire network upgraded to (initial) protocol version 209, crtainl simplifications in the source code are possible.
* Update all copyrights to 2012Gavin Andresen2012-02-071-1/+1
|
* Fix handling of default portsPieter Wuille2012-01-171-1/+1
|
* Network stack refactorPieter Wuille2012-01-061-31/+8
| | | | | | | | | | | | | | | This introduces CNetAddr and CService, respectively wrapping an (IPv6) IP address and an IP+port combination. This functionality used to be part of CAddress, which also contains network flags and connection attempt information. These extra fields are however not always necessary. These classes, along with logic for creating connections and doing name lookups, are moved to netbase.{h,cpp}, which does not depend on headers.h. Furthermore, CNetAddr is mostly IPv6-ready, though IPv6 functionality is not yet enabled for the application itself.
* Revert "Use standard C99 (and Qt) types for 64-bit integers"Wladimir J. van der Laan2011-12-211-9/+7
| | | | This reverts commit 21d9f36781604e4ca9fc35dc65265593423b73e9.
* Use standard C99 (and Qt) types for 64-bit integersLuke Dashjr2011-12-201-7/+9
|
* Move CInv to protocol.[ch]ppGiel van Schijndel2011-08-191-0/+27
| | | | | | | This commit does *not* and should not modify *any* code, it only moves it from net.h and splits it across protocol.cpp and protocol.hpp. Signed-off-by: Giel van Schijndel <[email protected]>
* Move CAddress to protocol.[ch]ppGiel van Schijndel2011-08-191-0/+71
| | | | | | | This commit does *not* and should not modify *any* code, it only moves it from net.h and splits it across protocol.cpp and protocol.hpp. Signed-off-by: Giel van Schijndel <[email protected]>
* Start moving protocol-specific code to protocol.[ch]ppGiel van Schijndel2011-08-191-0/+52
Move CMessageHeader from net.h to protocol.[ch]pp, with the implementation in the .cpp compilation unit (compiling once is enough). This commit does *not* and should not modify *any* code, it only moves it from net.h and splits it across protocol.cpp and protocol.hpp. Indentation changes aside the closest thing to a modification of code is the addition of the 'TODO' comment (the execution of which requires code modifications and thus doesn't belong in this commit). Signed-off-by: Giel van Schijndel <[email protected]>