summaryrefslogtreecommitdiff
path: root/io.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-05-27 18:06:42 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-05-27 18:06:42 +0000
commit9efb5a9d6a14d140b5b2e958e84974da02a07324 (patch)
tree82a303ca0b10f1ef6e8115e344e9e51773746dbc /io.c
parent412e9ba17447fc3460d8d1b2203cf53efa1b2ee7 (diff)
* io.c (fill_cbuf): return MORE_CHAR_SUSPENDED when cbuf is not empty.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31758 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r--io.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/io.c b/io.c
index 20d526dfe0..4e1945c549 100644
--- a/io.c
+++ b/io.c
@@ -1720,6 +1720,9 @@ fill_cbuf(rb_io_t *fptr, int ec_flags)
}
}
}
+ if (cbuf_len0 != fptr->cbuf.len)
+ return MORE_CHAR_SUSPENDED;
+
return MORE_CHAR_FINISHED;
}