mirror of
https://github.com/ruby/ruby.git
synced 2025-09-19 18:43:59 +02:00
* process.c (try_with_sh): take envp argument.
(exec_with_sh): ditto. use it for execve. (proc_exec_v): provide envp for try_with_sh. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35943 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
96b96832c1
commit
7685837427
3 changed files with 21 additions and 5 deletions
|
@ -1297,6 +1297,11 @@ class TestProcess < Test::Unit::TestCase
|
|||
open("tmp_script.#{$$}", "w") {|f| f.puts "echo $#: $@"; f.chmod(0755)}
|
||||
result = IO.popen(["./tmp_script.#{$$}", "a b", "c"]) {|f| f.read}
|
||||
assert_equal("2: a b c\n", result, feature)
|
||||
|
||||
open("tmp_script.#{$$}", "w") {|f| f.puts "echo $hghg"; f.chmod(0755)}
|
||||
result = IO.popen([{"hghg" => "mogomogo"}, "./tmp_script.#{$$}", "a b", "c"]) {|f| f.read}
|
||||
assert_equal("mogomogo\n", result, feature)
|
||||
|
||||
end
|
||||
end if File.executable?("/bin/sh")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue