From f4cf8ea423d8f9df1d341adba63d1416779aae8a Mon Sep 17 00:00:00 2001 From: Yukihiro Matsumoto Date: Wed, 9 May 2012 08:49:38 +0900 Subject: partial VC support --- src/string.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/string.c') diff --git a/src/string.c b/src/string.c index 183763bf2..dc7fdfae8 100644 --- a/src/string.c +++ b/src/string.c @@ -3843,6 +3843,7 @@ mrb_cstr_to_inum(mrb_state *mrb, const char *str, int base, int badcheck) // long i; // mrb_value z; // BDIGIT *zds; + unsigned long val; #undef ISDIGIT #define ISDIGIT(c) ('0' <= (c) && (c) <= '9') @@ -3958,7 +3959,7 @@ mrb_cstr_to_inum(mrb_state *mrb, const char *str, int base, int badcheck) } len *= strlen(str)*sizeof(char); - unsigned long val = strtoul((char*)str, &end, base); + val = strtoul((char*)str, &end, base); if (badcheck) { if (end == str) goto bad; /* no number */ -- cgit v1.2.3