diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 1998-03-13 09:04:32 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 1998-03-13 09:04:32 +0000 |
commit | 056f219ecaa8daa50a77d28bed49fb5a4bf75928 (patch) | |
tree | 331b0dad1cf037e44c5fd9841d02145a86d3494c /io.c | |
parent | 107ead2b961452a8df2d0b63eda34b45d9b4ef75 (diff) |
1.1b9_02
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@122 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'io.c')
-rw-r--r-- | io.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -369,7 +369,7 @@ io_gets_method(argc, argv, io) VALUE rs; if (argc == 0) { - return io_gets(io); + rs = RS; } else { rb_scan_args(argc, argv, "1", &rs); @@ -394,7 +394,6 @@ io_gets_method(argc, argv, io) rsptr = 0; rslen = 0; } - newline = rslen ? rsptr[rslen - 1] : 0777; GetOpenFile(io, fptr); io_readable(fptr); @@ -413,6 +412,7 @@ io_gets_method(argc, argv, io) } while (c != EOF); } + newline = rslen ? rsptr[rslen - 1] : 0777; { char buf[8192]; char *bp, *bpe = buf + sizeof buf - 3; |