* process.c (proc_spawn_v): should spawn, not exec.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29697 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
12ae5bb892
commit
1cf7194e0c
@ -1,3 +1,7 @@
|
|||||||
|
Fri Nov 5 12:17:59 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* process.c (proc_spawn_v): should spawn, not exec.
|
||||||
|
|
||||||
Fri Nov 5 01:21:31 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Fri Nov 5 01:21:31 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* process.c (proc_exec_v, proc_spawn_v): try to execute with sh if
|
* process.c (proc_exec_v, proc_spawn_v): try to execute with sh if
|
||||||
|
@ -1184,7 +1184,9 @@ proc_spawn_v(char **argv, char *prog)
|
|||||||
status = spawnv(P_WAIT, prog, argv);
|
status = spawnv(P_WAIT, prog, argv);
|
||||||
preserving_errno({
|
preserving_errno({
|
||||||
rb_last_status_set(status == -1 ? 127 : status, 0);
|
rb_last_status_set(status == -1 ? 127 : status, 0);
|
||||||
try_with_sh(prog, argv);
|
*argv = (char *)prog;
|
||||||
|
*--argv = (char *)"sh";
|
||||||
|
status = spawnv("/bin/sh", argv);
|
||||||
after_exec();
|
after_exec();
|
||||||
});
|
});
|
||||||
return status;
|
return status;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user