Set default alphabet if not specified.

This commit is contained in:
JoelKatz
2013-05-30 11:25:34 -07:00
parent 606b2a2942
commit 468588e3a0

View File

@@ -158,6 +158,8 @@ bool Base58::decode (const std::string& str, std::vector<unsigned char>& vchRet)
bool Base58::decodeWithCheck (const char* psz, std::vector<unsigned char>& vchRet, const char* pAlphabet)
{
if (pAlphabet == NULL)
pAlphabet = s_currentAlphabet;
if (!decode (psz, vchRet, pAlphabet))
return false;
if (vchRet.size() < 4)