summaryrefslogtreecommitdiff
path: root/ruby.c
diff options
context:
space:
mode:
Diffstat (limited to 'ruby.c')
-rw-r--r--ruby.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ruby.c b/ruby.c
index 944b6c7f5c..e016197e05 100644
--- a/ruby.c
+++ b/ruby.c
@@ -2011,7 +2011,7 @@ load_file_internal(VALUE argp_v)
else if (!NIL_P(c)) {
rb_io_ungetbyte(f, c);
}
- else {
+ if (NIL_P(c)) {
argp->f = f = Qnil;
}
if (!(opt->dump & ~DUMP_BIT(version_v))) {