diff options
author | ngoto <ngoto@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-06-19 17:49:27 +0000 |
---|---|---|
committer | ngoto <ngoto@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-06-19 17:49:27 +0000 |
commit | 10d5ad64c335d057b03253babafd1c41e2cb8898 (patch) | |
tree | 3cf9534aa853c6d8a8c6b3f4233a356311ff76e8 /enc | |
parent | 72af47628bd529c8a24bb3beba9eef485b58b8a3 (diff) | |
download | ruby-10d5ad64c335d057b03253babafd1c41e2cb8898.tar.gz |
* process.c (rb_execarg_parent_start1): new macro ALWAYS_NEED_ENVP
to generate envp_str anytime on Solaris 10 (or earlier version
of Solaris) to avoid calling execv() which is async-signal unsafe
on Solaris 10. [Bug #11265] [ruby-dev:49089]
* process.c (exec_with_sh, proc_exec_cmd): On Solaris 10,
because ALWAYS_NEED_ENVP is 1 and envp_str is always generated,
execv() in exec_with_sh() and proc_exec_cmd() are never called.
To guarantee this, execv() is replaced by a macro to print
out error message on Solaris 10.
* process.c (proc_exec_sh): Because proc_exec_sh() may be called
by rb_proc_exec() with envp_str = Qfalse, execl() is replaced
by a macro that calls execle() with "extern char **environ"
traditional global variable on Solaris 10.
TODO: This may be unsafe and sholud be changed
in the future.
Although rb_proc_exec() is not used from inside current version
of ruby, it may be called by third-party extensions.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'enc')
0 files changed, 0 insertions, 0 deletions