lib/childprocess/windows/process.rb in childprocess-0.1.5 vs lib/childprocess/windows/process.rb in childprocess-0.1.6
- old
+ new
@@ -38,21 +38,26 @@
def launch_process
opts = {
:inherit => false,
:detach => detach?,
+ :duplex => duplex?
}
if @io
opts[:stdout] = @io.stdout
opts[:stderr] = @io.stderr
end
- # TODO: escape/quote arguments properly
- command = @args.join ' '
+ # TODO: escape/quote arguments properly
+ command = @args.join ' '
@pid = Lib.create_proc(command, opts)
@handle = Handle.open(@pid)
+
+ if duplex?
+ io._stdin = opts[:stdin]
+ end
self
end
end # Process