aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2011-06-16 11:13:22 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2011-06-16 11:13:22 -0300
commitcf0562e1e720581f1b5c05dc9cc55a0857c94639 (patch)
tree31aa5a4f2233158c14d88a490ecec42a11107c5b
parent22e1c5ebadc63f4b6aa1b2db82067151041e75c7 (diff)
downloadlua-cf0562e1e720581f1b5c05dc9cc55a0857c94639.tar.gz
lua-cf0562e1e720581f1b5c05dc9cc55a0857c94639.tar.bz2
lua-cf0562e1e720581f1b5c05dc9cc55a0857c94639.zip
detail (missing cast to unsigned char when converting char to int)
-rw-r--r--lobject.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lobject.c b/lobject.c
index 7b7110cb..fd81f73b 100644
--- a/lobject.c
+++ b/lobject.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lobject.c,v 2.48 2011/05/03 16:01:57 roberto Exp roberto $ 2** $Id: lobject.c,v 2.49 2011/05/31 18:24:36 roberto Exp roberto $
3** Some generic functions over Lua objects 3** Some generic functions over Lua objects
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -105,7 +105,7 @@ static int isneg (const char **s) {
105 105
106static lua_Number readhexa (const char **s, lua_Number r, int *count) { 106static lua_Number readhexa (const char **s, lua_Number r, int *count) {
107 while (lisxdigit(cast_uchar(**s))) { /* read integer part */ 107 while (lisxdigit(cast_uchar(**s))) { /* read integer part */
108 r = (r * 16.0) + (double)luaO_hexavalue(*(*s)++); 108 r = (r * 16.0) + cast_num(luaO_hexavalue(cast_uchar(*(*s)++)));
109 (*count)++; 109 (*count)++;
110 } 110 }
111 return r; 111 return r;