Issue #7718 has been updated by vo.x (Vit Ondruch).


=begin
This is the output:
 # ./a.out 
 40045200

And here is my testing IRB session:

 # irb
 irb(main):001:0> File.open('/dev/urandom'){|f1|
 irb(main):002:1*         entropy_count = ""
 irb(main):003:1>         # get entropy count
 irb(main):004:1*         f1.ioctl(0x80045200, entropy_count)
 irb(main):005:1>       }
 Errno::EINVAL: Invalid argument - /dev/urandom
 	from (irb):4:in `ioctl'
 	from (irb):4:in `block in irb_binding'
 	from (irb):1:in `open'
 	from (irb):1
 	from /usr/bin/irb:12:in `<main>'
 irb(main):006:0> File.open('/dev/urandom'){|f1|
 irb(main):007:1*         entropy_count = ""
 irb(main):008:1>         f1.ioctl(0x40045200, entropy_count)
 irb(main):009:1> }
 => 0
 irb(main):010:0> 

And similar script run with strace: http://paste.fedoraproject.org/2489/
=end

----------------------------------------
Bug #7718: test_ioctl_linux fails on PPC and PPC64
https://bugs.ruby-lang.org/issues/7718#change-35523

Author: vo.x (Vit Ondruch)
Status: Feedback
Priority: Normal
Assignee: 
Category: 
Target version: 
ruby -v: ruby -v: ruby 2.0.0dev (2013-01-16 trunk 38848) [powerpc-linux] and ruby 1.9.3p362 (2012-12-25 revision 38607) [powerpc64-linux]


=begin
 test_ioctl_linux(TestIO) [/builddir/build/BUILD/ruby-2.0.0-r38848/test/ruby/test_io.rb:2443]:
 Exception raised:
 <#<Errno::EINVAL: Invalid argument - /dev/urandom>>.

The above mentioned test case fails on PPC and PPC64. The test case was introduced in 33716. It fails with Ruby 2.0 and Ruby 1.9.3 as well.
=end




-- 
http://bugs.ruby-lang.org/