mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Use mrb_int_value() instead of mrb_fixnum_value(); fix #5142
This commit is contained in:
+1
-1
@@ -2378,7 +2378,7 @@ mrb_str_len_to_inum(mrb_state *mrb, const char *str, size_t len, mrb_int base, i
|
||||
if (p<pend) goto bad; /* trailing garbage */
|
||||
}
|
||||
|
||||
return mrb_fixnum_value(sign ? val : -val);
|
||||
return mrb_int_value(mrb, sign ? val : -val);
|
||||
nullbyte:
|
||||
mrb_raise(mrb, E_ARGUMENT_ERROR, "string contains null byte");
|
||||
/* not reached */
|
||||
|
||||
Reference in New Issue
Block a user