diff options
author | Andrew Chambers <andrewchambers@fastmail.com> | 2019-02-15 20:03:29 +1300 |
---|---|---|
committer | Michael Forney <mforney@mforney.org> | 2019-02-15 00:06:53 -0800 |
commit | 35998a93f9a59a34477890637fda75982d9a5e1c (patch) | |
tree | 436cb4d6ac0d5e89c8ebc38985676184b5b70072 | |
parent | ca6384fcf7fea13e095c278fec7f3e20c943ad62 (diff) |
Fix hex escape in char literals.
-rw-r--r-- | expr.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -148,7 +148,7 @@ unescape(char **p) ++s; assert(isxdigit(*s)); c = 0; - do c = c * 16 + (*s > '9' ? tolower(*s) - 'a' : *s - '0'); + do c = c * 16 + (*s > '9' ? 10 + tolower(*s) - 'a' : *s - '0'); while (isxdigit(*++s)); break; default: |