| 737 | json_token_t *token); |
| 738 | |
| 739 | static int hexdigit2int(char hex) |
| 740 | { |
| 741 | if ('0' <= hex && hex <= '9') |
| 742 | return hex - '0'; |
| 743 | |
| 744 | /* Force lowercase */ |
| 745 | hex |= 0x20; |
| 746 | if ('a' <= hex && hex <= 'f') |
| 747 | return 10 + hex - 'a'; |
| 748 | |
| 749 | return -1; |
| 750 | } |
| 751 | |
| 752 | static int decode_hex4(const char *hex) |
| 753 | { |