aboutsummaryrefslogtreecommitdiff
path: root/src/base58.h
diff options
context:
space:
mode:
authorDoug Huff <[email protected]>2011-06-06 12:47:19 -0500
committerDoug Huff <[email protected]>2011-06-06 12:49:11 -0500
commita9d3af88214b37ea61394b0b5abee6d380f9a5f0 (patch)
tree7b263d01a517fd72c8e94161415abbc59f1577b8 /src/base58.h
parentReduce minimum TX fee for new transactions, to 0.0005. (diff)
downloaddiscoin-a9d3af88214b37ea61394b0b5abee6d380f9a5f0.tar.xz
discoin-a9d3af88214b37ea61394b0b5abee6d380f9a5f0.zip
Demystify a few magic numbers.
Diffstat (limited to 'src/base58.h')
-rw-r--r--src/base58.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/base58.h b/src/base58.h
index 580bd3fc6..c2729d477 100644
--- a/src/base58.h
+++ b/src/base58.h
@@ -38,6 +38,8 @@ inline std::string EncodeBase58(const unsigned char* pbegin, const unsigned char
// Convert bignum to std::string
std::string str;
+ // Expected size increase from base58 conversion is approximately 137%
+ // use 138% to be safe
str.reserve((pend - pbegin) * 138 / 100 + 1);
CBigNum dv;
CBigNum rem;