Skip to content

Kernel.spawn doesn't support some options (ex: :chdir) #985

@tagomoris

Description

@tagomoris

Some options like :pgroup works, but others (ex: :chdir, filehandles) doesn't work.

$ jruby -e 'pid = spawn("sleep 5", :pgroup => 0, :chdir => "/", STDOUT => :close); p pid; Process.detach(pid)'
file:/Users/tagomoris/.rbenv/versions/jruby-1.7.4/lib/jruby.jar!/jruby/kernel19/process.rb:4 warning: unsupported spawn option: chdir
TypeError: wrong exec option: RubyIO(66, 1)
  _spawn_internal at org/jruby/RubyProcess.java:1067
            spawn at file:/Users/tagomoris/.rbenv/versions/jruby-1.7.4/lib/jruby.jar!/jruby/kernel19/process.rb:3
            spawn at file:/Users/tagomoris/.rbenv/versions/jruby-1.7.4/lib/jruby.jar!/jruby/kernel19/kernel.rb:29
           (root) at -e:1

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions