mirror of
https://github.com/ruby/ruby.git
synced 2025-09-22 03:53:58 +02:00
* io.c (io_getc): should be 7bit if ascii. fixes #4557
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32000 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
6f58118e4c
commit
34b19050b3
3 changed files with 14 additions and 1 deletions
|
@ -2060,5 +2060,14 @@ EOT
|
|||
r.close
|
||||
end)
|
||||
end
|
||||
|
||||
def test_getc_ascii_only
|
||||
bug4557 = '[ruby-core:35630]'
|
||||
c = with_tmpdir {
|
||||
open("a", "wb") {|f| f.puts "a"}
|
||||
open("a", "rt") {|f| f.getc}
|
||||
}
|
||||
assert(c.ascii_only?, "should be ascii_only #{bug4557}")
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue