diff --git a/ChangeLog b/ChangeLog index 085be0630b..805d78f2bd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +Mon May 19 13:23:03 2008 NAKAMURA Usaku + + * process.c (rb_spawn_internal): set last_status when status == -1 + because there is no path to set it on win32. this patch is derived + from [ruby-core:16787], submitted by Luis Lavena + Mon May 19 11:32:47 2008 Koichi Sasada * vm.c, insns.def, eval.c, vm_insnhelper.c: fix CREF handling. diff --git a/process.c b/process.c index b5be40372d..682ba259bc 100644 --- a/process.c +++ b/process.c @@ -2674,6 +2674,10 @@ rb_spawn_internal(int argc, VALUE *argv, int default_close_others) else { status = proc_spawn_n(argc, argv, prog); } +# if defined(_WIN32) + if (status == -1) + rb_last_status_set(0x7f << 8, 0); +# endif # else if (argc) prog = rb_ary_join(rb_ary_new4(argc, argv), rb_str_new2(" ")); status = system(StringValuePtr(prog));