diff options
| author | practicalswift <[email protected]> | 2017-08-24 09:19:00 +0200 |
|---|---|---|
| committer | practicalswift <[email protected]> | 2017-08-24 09:19:40 +0200 |
| commit | c6a995e7e5e6ae37dc1684f6060038e96864e947 (patch) | |
| tree | 703ce13f674552e44683ec73f3cc01bcdb69a6a5 /src/base58.cpp | |
| parent | Merge #10997: RPC: Add option -stdinrpcpass to bitcoin-cli to allow RPC passw... (diff) | |
| download | discoin-c6a995e7e5e6ae37dc1684f6060038e96864e947.tar.xz discoin-c6a995e7e5e6ae37dc1684f6060038e96864e947.zip | |
Improve readability of DecodeBase58Check(...)
Diffstat (limited to 'src/base58.cpp')
| -rw-r--r-- | src/base58.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/base58.cpp b/src/base58.cpp index 3802f953f..56acf392c 100644 --- a/src/base58.cpp +++ b/src/base58.cpp @@ -136,7 +136,7 @@ bool DecodeBase58Check(const char* psz, std::vector<unsigned char>& vchRet) } // re-calculate the checksum, ensure it matches the included 4-byte checksum uint256 hash = Hash(vchRet.begin(), vchRet.end() - 4); - if (memcmp(&hash, &vchRet.end()[-4], 4) != 0) { + if (memcmp(&hash, &vchRet[vchRet.size() - 4], 4) != 0) { vchRet.clear(); return false; } |