summaryrefslogtreecommitdiffstats
path: root/lldb/source/Utility/StringExtractor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/source/Utility/StringExtractor.cpp')
-rw-r--r--lldb/source/Utility/StringExtractor.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lldb/source/Utility/StringExtractor.cpp b/lldb/source/Utility/StringExtractor.cpp
index d2f69f95b7c..86cd623f55c 100644
--- a/lldb/source/Utility/StringExtractor.cpp
+++ b/lldb/source/Utility/StringExtractor.cpp
@@ -17,18 +17,20 @@
static inline int
xdigit_to_sint (char ch)
{
- ch = tolower(ch);
if (ch >= 'a' && ch <= 'f')
return 10 + ch - 'a';
+ if (ch >= 'A' && ch <= 'F')
+ return 10 + ch - 'A';
return ch - '0';
}
static inline unsigned int
xdigit_to_uint (uint8_t ch)
{
- ch = tolower(ch);
if (ch >= 'a' && ch <= 'f')
return 10u + ch - 'a';
+ if (ch >= 'A' && ch <= 'F')
+ return 10u + ch - 'A';
return ch - '0';
}
OpenPOWER on IntegriCloud