mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 05:29:10 +02:00
Initialize goruby only when executing
This commit is contained in:
parent
ecb58a8d08
commit
6e544f2fed
1 changed files with 2 additions and 1 deletions
3
goruby.c
3
goruby.c
|
@ -60,7 +60,8 @@ int
|
|||
goruby_run_node(void *arg)
|
||||
{
|
||||
int state;
|
||||
if (NIL_P(rb_protect(init_golf, Qtrue, &state))) {
|
||||
if (ruby_executable_node(arg, NULL) &&
|
||||
NIL_P(rb_protect(init_golf, Qtrue, &state))) {
|
||||
return state == EXIT_SUCCESS ? EXIT_FAILURE : state;
|
||||
}
|
||||
return ruby_run_node(arg);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue