diff options
| author | Pieter Wuille <[email protected]> | 2014-09-01 21:00:32 +0200 |
|---|---|---|
| committer | Pieter Wuille <[email protected]> | 2014-09-01 21:23:01 +0200 |
| commit | 2e731f24b5a5c894e013a6d752f1cd409303e916 (patch) | |
| tree | 94ba6f1e3ab9ecb5ac1696b48b1aabc859aa8365 /src/addrman.h | |
| parent | Merge pull request #4779 (diff) | |
| parent | Use CSizeComputer to avoid counting sizes in SerializationOp (diff) | |
| download | discoin-2e731f24b5a5c894e013a6d752f1cd409303e916.tar.xz discoin-2e731f24b5a5c894e013a6d752f1cd409303e916.zip | |
Merge pull request #4737
31e9a83 Use CSizeComputer to avoid counting sizes in SerializationOp (Pieter Wuille)
84881f8 rework overhauled serialization methods to non-static (Kamil Domanski)
5d96b4a remove fields of ser_streamplaceholder (Kamil Domanski)
3d796f8 overhaul serialization code (Kamil Domanski)
Diffstat (limited to 'src/addrman.h')
| -rw-r--r-- | src/addrman.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/addrman.h b/src/addrman.h index 8f6ab6066..0790802b5 100644 --- a/src/addrman.h +++ b/src/addrman.h @@ -46,13 +46,15 @@ private: public: - IMPLEMENT_SERIALIZE( - CAddress* pthis = (CAddress*)(this); - READWRITE(*pthis); + IMPLEMENT_SERIALIZE; + + template <typename Stream, typename Operation> + inline void SerializationOp(Stream& s, Operation ser_action, int nType, int nVersion) { + READWRITE(*(CAddress*)this); READWRITE(source); READWRITE(nLastSuccess); READWRITE(nAttempts); - ) + } void Init() { |