diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-08-27 09:42:26 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2020-10-12 18:20:05 +0900 |
| commit | 5134031e189e1cdde198e1c09f7b1d22bf2a1ce0 (patch) | |
| tree | c6f9ad2f670c7aa50690f073a6e756f568cbcf00 /mrbgems/mruby-io/src/file.c | |
| parent | befcbd5607a060e5e619cae7333512c8bdde32f6 (diff) | |
| download | mruby-5134031e189e1cdde198e1c09f7b1d22bf2a1ce0.tar.gz mruby-5134031e189e1cdde198e1c09f7b1d22bf2a1ce0.zip | |
Use `mrb_int_value()` instead of `mrb_fixnum_value()`.
Where fixnum overflow can happen.
Diffstat (limited to 'mrbgems/mruby-io/src/file.c')
| -rw-r--r-- | mrbgems/mruby-io/src/file.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mrbgems/mruby-io/src/file.c b/mrbgems/mruby-io/src/file.c index a28360d81..d272cab7d 100644 --- a/mrbgems/mruby-io/src/file.c +++ b/mrbgems/mruby-io/src/file.c @@ -399,7 +399,7 @@ mrb_file_mtime(mrb_state *mrb, mrb_value self) if (mrb_fstat(fd, &st) == -1) return mrb_false_value(); - return mrb_fixnum_value((mrb_int)st.st_mtime); + return mrb_int_value(mrb, (mrb_int)st.st_mtime); } static mrb_value |
