summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authornahi <nahi@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-12-21 06:33:05 +0000
committernahi <nahi@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-12-21 06:33:05 +0000
commitf9df459a31bef331ed0610b859effde63ea9a674 (patch)
treeef1aea83ff6dff2ee9a3f473d6403364d9c377c2 /ext
parentac714c2d300eeb58ef1e19bbef1af4bedaec89d2 (diff)
* ext/stringio/stringio.c (strio_getline): fix for "" as separator.
[ruby-dev:34591] (Backport r17739 by Yusuke Endoh from trunk). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@26140 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext')
-rw-r--r--ext/stringio/stringio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/stringio/stringio.c b/ext/stringio/stringio.c
index 16a836454f..c38c92eb82 100644
--- a/ext/stringio/stringio.c
+++ b/ext/stringio/stringio.c
@@ -935,7 +935,7 @@ strio_getline(argc, argv, ptr)
s = p;
while ((p = memchr(p, '\n', e - p)) && (p != e)) {
if (*++p == '\n') {
- e = p;
+ e = p + 1;
break;
}
}