diff options
author | Suhas Daftuar <sdaftuar@gmail.com> | 2017-05-07 14:10:19 -0400 |
---|---|---|
committer | Suhas Daftuar <sdaftuar@chaincode.com> | 2017-09-05 15:05:28 -0400 |
commit | 0311836f6927aec4ba5687ea12af35df3c509682 (patch) | |
tree | 5d1b35310828f7299e039476a52146140f6bb0fc /src/utilstrencodings.h | |
parent | e0e3cbbf081b74ed5322176dcda081c64076fd21 (diff) |
Allow setting nMinimumChainWork on command line
Diffstat (limited to 'src/utilstrencodings.h')
-rw-r--r-- | src/utilstrencodings.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/utilstrencodings.h b/src/utilstrencodings.h index 53da60e8f1..192f33fb29 100644 --- a/src/utilstrencodings.h +++ b/src/utilstrencodings.h @@ -38,7 +38,13 @@ std::string SanitizeString(const std::string& str, int rule = SAFE_CHARS_DEFAULT std::vector<unsigned char> ParseHex(const char* psz); std::vector<unsigned char> ParseHex(const std::string& str); signed char HexDigit(char c); +/* Returns true if each character in str is a hex character, and has an even + * number of hex digits.*/ bool IsHex(const std::string& str); +/** +* Return true if the string is a hex number, optionally prefixed with "0x" +*/ +bool IsHexNumber(const std::string& str); std::vector<unsigned char> DecodeBase64(const char* p, bool* pfInvalid = nullptr); std::string DecodeBase64(const std::string& str); std::string EncodeBase64(const unsigned char* pch, size_t len); |