aboutsummaryrefslogtreecommitdiff
path: root/src/hash.h
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2016-10-28 21:55:12 -0700
committerPieter Wuille <pieter.wuille@gmail.com>2016-11-07 09:39:46 -0800
commitc2c5d42f36f4440aaddc4a64974a52fdb07af08b (patch)
tree121eb8fbd0c3fa2378c900bd411c3a6c0eb7d2ab /src/hash.h
parent50e8a9ccd78c8c20c3eac6618da7293078446b58 (diff)
downloadbitcoin-c2c5d42f36f4440aaddc4a64974a52fdb07af08b.tar.xz
Make streams' read and write return void
The stream implementations had two cascading layers (the upper one with operator<< and operator>>, and a lower one with read and write). The lower layer's functions are never cascaded (nor should they, as they should only be used from the higher layer), so make them return void instead.
Diffstat (limited to 'src/hash.h')
-rw-r--r--src/hash.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/hash.h b/src/hash.h
index db4e130ae7..88926ab31f 100644
--- a/src/hash.h
+++ b/src/hash.h
@@ -138,9 +138,8 @@ public:
CHashWriter(int nTypeIn, int nVersionIn) : nType(nTypeIn), nVersion(nVersionIn) {}
- CHashWriter& write(const char *pch, size_t size) {
+ void write(const char *pch, size_t size) {
ctx.Write((const unsigned char*)pch, size);
- return (*this);
}
// invalidates the object