aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--expr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/expr.c b/expr.c
index 75c0423..88cf764 100644
--- a/expr.c
+++ b/expr.c
@@ -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: