IO.popen in windows ignores pwd
-------------------------------

                 Key: JRUBY-5755
                 URL: http://jira.codehaus.org/browse/JRUBY-5755
             Project: JRuby
          Issue Type: Bug
          Components: Windows
    Affects Versions: JRuby 1.6.1
         Environment:  "jruby 1.6.1 (ruby-1.8.7-p330) (2011-04-12 85838f6) 
(Java HotSpot(TM) Client VM 1.6.0_24) [Windows 7-x86-java]"
            Reporter: Roger Pack


viz:

>> Dir.pwd
=> "C:/Program Files (x86)/VideoLAN/VLC"
>> Dir['*.exe']
=> ["uninstall.exe", "vlc-cache-gen.exe", "vlc.exe"]
>> IO.popen("vlc.exe c:\\silence").pid
=> 728 # works, though wrong pid, but that's for a different JIRA
>> IO.popen("vlc.exe").pid
IOError: Cannot run program "vlc.exe" (in directory "C:\Program Files 
(x86)\VideoLAN\VLC"): CreateProcess error=2, The system cannot find the file 
specified
        from org/jruby/RubyIO.java:3702:in `popen'
        from (irb):29:in `evaluate'
        from org/jruby/RubyKernel.java:1087:in `eval'
        from g:/installs/jruby-1.6.0/lib/ruby/1.8/irb.rb:158:in `eval_input'
        from g:/installs/jruby-1.6.0/lib/ruby/1.8/irb.rb:271:in `signal_status'
        from g:/installs/jruby-1.6.0/lib/ruby/1.8/irb.rb:270:in `signal_status'
        from g:/installs/jruby-1.6.0/lib/ruby/1.8/irb.rb:155:in `eval_input'
        from org/jruby/RubyKernel.java:1417:in `loop'
        from org/jruby/RubyKernel.java:1190:in `catch'
        from g:/installs/jruby-1.6.0/lib/ruby/1.8/irb.rb:154:in `eval_input'
        from g:/installs/jruby-1.6.0/lib/ruby/1.8/irb.rb:71:in `start'
        from org/jruby/RubyKernel.java:1190:in `catch'
        from g:/installs/jruby-1.6.0/lib/ruby/1.8/irb.rb:70:in `start'
        from g:/installs/jruby-1.6.0/bin/jirb:13:in `(root)'

The last failure is surprising, and isn't how MRI acts.

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