IO.popen4 reading from the wrong socket results in wrong error message
----------------------------------------------------------------------

                 Key: JRUBY-4932
                 URL: http://jira.codehaus.org/browse/JRUBY-4932
             Project: JRuby
          Issue Type: Bug
            Reporter: Roger Pack
            Assignee: Thomas E Enebo
            Priority: Minor


>> p,i,o,e = IO.popen4("..\\vendor\\gocr048.exe")
=> [444, #<IO:0x10980e7>, #<IO:0xedbe39>, #<IO:0x639bf1>]
irb(main):002:0> r.read
Java::JavaNioChannels::NonReadableChannelException: 
#<Java::JavaNioChannels::NonReadableChannelException:0xc017e9>
        from sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:134)
        from 
org.jruby.util.io.ChannelDescriptor.read(ChannelDescriptor.java:542)

It probably wants to look like this:

>> i.read
IOError: not opened for reading
        from (irb):7:in `read'

Since that's what MRI's popen3 input streams do.
Cheers! 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to