summaryrefslogtreecommitdiff
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 17e33d8cb9..e4c7763572 100644
--- a/io.c
+++ b/io.c
@@ -3575,9 +3575,9 @@ io_getc(rb_io_t *fptr, rb_encoding *enc)
VALUE str;
if (NEED_READCONV(fptr)) {
- VALUE str = Qnil;
rb_encoding *read_enc = io_read_encoding(fptr);
+ str = Qnil;
SET_BINARY_MODE(fptr);
make_readconv(fptr, 0);