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 eb7563009f..d39830dabf 100644
--- a/ruby.c
+++ b/ruby.c
@@ -580,7 +580,7 @@ load_file(fname, script)
if (script) {
rb_define_global_const("DATA", f);
}
- if (f != rb_stdin) {
+ else if (f != rb_stdin) {
io_close(f);
}
}