Update is_valid_hex_char
This commit is contained in:
parent
ba813ea5bf
commit
9cba0172b9
@ -370,23 +370,7 @@ bool strequal(const char *const first, const char *const second) {
|
||||
}
|
||||
|
||||
bool is_valid_hex_char(const char input) {
|
||||
switch (input) {
|
||||
case 'A':
|
||||
case 'B':
|
||||
case 'C':
|
||||
case 'D':
|
||||
case 'E':
|
||||
case 'F':
|
||||
case 'a':
|
||||
case 'b':
|
||||
case 'c':
|
||||
case 'd':
|
||||
case 'e':
|
||||
case 'f':
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
return (input >= 'A' && input <= 'F') || (input >= 'a' && input <= 'e');
|
||||
}
|
||||
|
||||
bool ishex(const char input) {
|
||||
|
Loading…
Reference in New Issue
Block a user