describe about waiting a child process.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16209 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
4ce308d6a4
commit
6fb36ebab0
|
@ -42,8 +42,6 @@ module Open3
|
||||||
#
|
#
|
||||||
# Block form:
|
# Block form:
|
||||||
#
|
#
|
||||||
# require 'open3'
|
|
||||||
#
|
|
||||||
# Open3.popen3(cmd) { |stdin, stdout, stderr| ... }
|
# Open3.popen3(cmd) { |stdin, stdout, stderr| ... }
|
||||||
# # stdin, stdout and stderr is closed automatically in this form.
|
# # stdin, stdout and stderr is closed automatically in this form.
|
||||||
#
|
#
|
||||||
|
@ -83,6 +81,11 @@ module Open3
|
||||||
#
|
#
|
||||||
# The parameter +cmd+ is passed directly to Kernel#spawn.
|
# The parameter +cmd+ is passed directly to Kernel#spawn.
|
||||||
#
|
#
|
||||||
|
# wait_thr.value waits the termination of the process.
|
||||||
|
# The block form also waits the process when it returns.
|
||||||
|
#
|
||||||
|
# Closing stdin, stdout and stderr does not wait the process.
|
||||||
|
#
|
||||||
def popen3w(*cmd)
|
def popen3w(*cmd)
|
||||||
pw = IO::pipe # pipe[0] for read, pipe[1] for write
|
pw = IO::pipe # pipe[0] for read, pipe[1] for write
|
||||||
pr = IO::pipe
|
pr = IO::pipe
|
||||||
|
|
Loading…
Reference in New Issue