diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-05-22 06:19:03 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-05-22 06:19:03 +0000 |
commit | a815b56d84e1876c5f6e5fc9f4b3bc46a1a3cfb3 (patch) | |
tree | b5e4c4984ab8ec16857a927e71ddb33cc406fb37 /test | |
parent | 38302ca7195981b7f4994526378d9c90320d350f (diff) | |
download | ruby-a815b56d84e1876c5f6e5fc9f4b3bc46a1a3cfb3.tar.gz |
win32.c: check error of SetFilePointer
* win32/win32.c (setup_overlapped): check the error code in addition
to the result of SetFilePointer() to determine if an error occurred,
because INVALID_SET_FILE_POINTER is a valid value.
[ruby-core:55098] [Bug #8431]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40888 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r-- | test/ruby/test_io.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/ruby/test_io.rb b/test/ruby/test_io.rb index d44dd31e71..ca741f8a23 100644 --- a/test/ruby/test_io.rb +++ b/test/ruby/test_io.rb @@ -2673,4 +2673,15 @@ End IO.select(tempfiles) }, bug8080 end + + def test_seek_32bit_boundary + bug8431 = '[ruby-core:55098] [Bug #8431]' + make_tempfile {|t| + assert_ruby_status(["-e", <<-"end;", t.path], "", bug8431) + f = ARGF.to_io + f.seek(0xffff_ffff) + f.read(1) + end; + } + end end |