response "" for empty, fix value for some cases

This commit is contained in:
MichaelDvP
2024-07-25 17:58:38 +02:00
parent 9c80c92f06
commit 8adb35e47a
2 changed files with 4 additions and 6 deletions

View File

@@ -411,6 +411,7 @@ uint32_t Helpers::hextoint(const char * hex) {
// get current character then increment
char byte = *hex++;
// transform hex character to the 4bit equivalent number, using the ascii table indexes
if (byte == ' ') byte = *hex++; // skip spaces
if (byte >= '0' && byte <= '9')
byte = byte - '0';
else if (byte >= 'a' && byte <= 'f')