aboutsummaryrefslogtreecommitdiffstats
path: root/io.c
diff options
context:
space:
mode:
Diffstat (limited to 'io.c')
-rw-r--r--io.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/io.c b/io.c
index d3c6392fa2..980f8232bf 100644
--- a/io.c
+++ b/io.c
@@ -7716,7 +7716,7 @@ rb_file_initialize(int argc, VALUE *argv, VALUE io)
rb_raise(rb_eRuntimeError, "reinitializing File");
}
if (0 < argc && argc < 3) {
- VALUE fd = rb_check_convert_type(argv[0], T_FIXNUM, "Fixnum", "to_int");
+ VALUE fd = rb_check_to_int(argv[0]);
if (!NIL_P(fd)) {
argv[0] = fd;