diff options
author | Luke Dashjr <luke-jr+git@utopios.org> | 2012-04-22 10:05:43 -0400 |
---|---|---|
committer | Luke Dashjr <luke-jr+git@utopios.org> | 2012-04-22 10:05:43 -0400 |
commit | a93ab877877925c60b2dbf56bdde8aa46b6b7391 (patch) | |
tree | 3c473dd4151e38a72763600839a16f4a3b509325 /src/util.cpp | |
parent | e401e5eb79f944bf772e541baed9ef45f0cb4f43 (diff) | |
parent | d0fe14ffecda4af98ffe7b1523f9a903bf7518a0 (diff) | |
download | bitcoin-a93ab877877925c60b2dbf56bdde8aa46b6b7391.tar.xz |
Merge branch '0.4.x' into 0.5.x
Conflicts:
src/main.cpp
Diffstat (limited to 'src/util.cpp')
-rw-r--r-- | src/util.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/util.cpp b/src/util.cpp index 5b59eadaa2..211d1a036f 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -412,14 +412,14 @@ bool ParseMoney(const char* pszIn, int64& nRet) vector<unsigned char> ParseHex(const char* psz) { - static char phexdigit[256] = + static signed char phexdigit[256] = { -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, 0,1,2,3,4,5,6,7,8,9,-1,-1,-1,-1,-1,-1, -1,0xa,0xb,0xc,0xd,0xe,0xf,-1,-1,-1,-1,-1,-1,-1,-1,-1, -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, - -1,0xa,0xb,0xc,0xd,0xe,0xf,-1,-1,-1,-1,-1,-1,-1,-1,-1 + -1,0xa,0xb,0xc,0xd,0xe,0xf,-1,-1,-1,-1,-1,-1,-1,-1,-1, -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, @@ -436,12 +436,12 @@ vector<unsigned char> ParseHex(const char* psz) { while (isspace(*psz)) psz++; - char c = phexdigit[(unsigned char)*psz++]; - if (c == (char)-1) + signed char c = phexdigit[(unsigned char)*psz++]; + if (c == (signed char)-1) break; unsigned char n = (c << 4); c = phexdigit[(unsigned char)*psz++]; - if (c == (char)-1) + if (c == (signed char)-1) break; n |= c; vch.push_back(n); |