aboutsummaryrefslogtreecommitdiff
path: root/src/base58.cpp
diff options
context:
space:
mode:
authorJiaxing Wang <hello.wjx@gmail.com>2016-09-16 19:13:01 +0800
committerJiaxing Wang <hello.wjx@gmail.com>2016-09-16 19:13:01 +0800
commite892dc1268d33bfba01f35b70359b286bb9d6376 (patch)
tree7fbe95d40fcb635325166d4ca3592ea20b823a3a /src/base58.cpp
parent159ed95f7452ab5454e9d660f6f095b8476b1eed (diff)
Use prefix operator in for loop of DecodeBase58.
Diffstat (limited to 'src/base58.cpp')
-rw-r--r--src/base58.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/base58.cpp b/src/base58.cpp
index 405b67c153..f7768b5a64 100644
--- a/src/base58.cpp
+++ b/src/base58.cpp
@@ -42,7 +42,7 @@ bool DecodeBase58(const char* psz, std::vector<unsigned char>& vch)
// Apply "b256 = b256 * 58 + ch".
int carry = ch - pszBase58;
int i = 0;
- for (std::vector<unsigned char>::reverse_iterator it = b256.rbegin(); (carry != 0 || i < length) && (it != b256.rend()); it++, i++) {
+ for (std::vector<unsigned char>::reverse_iterator it = b256.rbegin(); (carry != 0 || i < length) && (it != b256.rend()); ++it, ++i) {
carry += 58 * (*it);
*it = carry % 256;
carry /= 256;