File tree Expand file tree Collapse file tree 3 files changed +2
-19
lines changed Expand file tree Collapse file tree 3 files changed +2
-19
lines changed Original file line number Diff line number Diff line change @@ -146,23 +146,6 @@ class HashWriter
146
146
}
147
147
};
148
148
149
- class CHashWriter : public HashWriter
150
- {
151
- private:
152
- const int nVersion;
153
-
154
- public:
155
- CHashWriter (int nVersionIn) : nVersion{nVersionIn} {}
156
-
157
- int GetVersion () const { return nVersion; }
158
-
159
- template <typename T>
160
- CHashWriter& operator <<(const T& obj) {
161
- ::Serialize (*this , obj);
162
- return (*this );
163
- }
164
- };
165
-
166
149
/* * Reads data from an underlying stream, while hashing the read data. */
167
150
template <typename Source>
168
151
class HashVerifier : public HashWriter
Original file line number Diff line number Diff line change 10
10
11
11
uint256 CBlockHeader::GetHash () const
12
12
{
13
- return (CHashWriter{PROTOCOL_VERSION } << *this ).GetHash ();
13
+ return (HashWriter{ } << *this ).GetHash ();
14
14
}
15
15
16
16
std::string CBlock::ToString () const
Original file line number Diff line number Diff line change @@ -122,7 +122,7 @@ BOOST_AUTO_TEST_CASE(siphash)
122
122
(uint64_t (x+4 )<<32 )|(uint64_t (x+5 )<<40 )|(uint64_t (x+6 )<<48 )|(uint64_t (x+7 )<<56 ));
123
123
}
124
124
125
- CHashWriter ss{CLIENT_VERSION };
125
+ HashWriter ss{};
126
126
CMutableTransaction tx;
127
127
// Note these tests were originally written with tx.nVersion=1
128
128
// and the test would be affected by default tx version bumps if not fixed.
You can’t perform that action at this time.
0 commit comments