青木です。
かねがね思っていたのですが、Process.fork があるのに Process.exec が
ないのは釣り合いが悪いと思います。新設しませんか。
ついでに警告避けの rb_raise のパッチもつけます。
Index: process.c
===================================================================
RCS file: /var/cvs/src/ruby/process.c,v
retrieving revision 1.142
diff -u -r1.142 process.c
--- process.c 20 Nov 2005 03:30:43 -0000 1.142
+++ process.c 23 Dec 2005 22:25:13 -0000
@@ -2632,7 +2632,7 @@
ngroups = RARRAY(ary)->len;
if (ngroups > maxgroups)
- rb_raise(rb_eArgError, "too many groups, %d max", maxgroups);
+ rb_raise(rb_eArgError, "too many groups, %lu max", (unsigned long)maxgroups);
groups = ALLOCA_N(rb_gid_t, ngroups);
@@ -3583,6 +3583,7 @@
#endif
#endif
+ rb_define_singleton_method(rb_mProcess, "exec", rb_f_exec, -1);
rb_define_singleton_method(rb_mProcess, "fork", rb_f_fork, 0);
rb_define_singleton_method(rb_mProcess, "spawn", rb_f_spawn, -1);
rb_define_singleton_method(rb_mProcess, "exit!", rb_f_exit_bang, -1);
--
青木峰郎