[前][次][番号順一覧][スレッド一覧]

ruby-changes:24888

From: naruse <ko1@a...>
Date: Mon, 10 Sep 2012 00:17:28 +0900 (JST)
Subject: [ruby-changes:24888] naruse:r36940 (trunk): * process.c: exec() requires to be single threaded also on Haiku.

naruse	2012-09-10 00:17:15 +0900 (Mon, 10 Sep 2012)

  New Revision: 36940

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=36940

  Log:
    * process.c: exec() requires to be single threaded also on Haiku.
      by Takashi Toyoshima <toyoshim@g...>
      https://github.com/ruby/ruby/pull/178

  Modified files:
    trunk/ChangeLog
    trunk/process.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 36939)
+++ ChangeLog	(revision 36940)
@@ -1,3 +1,9 @@
+Mon Sep 10 00:16:34 2012  NARUSE, Yui  <naruse@r...>
+
+	* process.c: exec() requires to be single threaded also on Haiku.
+	  by Takashi Toyoshima <toyoshim@g...>
+	  https://github.com/ruby/ruby/pull/178
+
 Sun Sep  9 21:21:15 2012  KOSAKI Motohiro  <kosaki.motohiro@g...>
 
 	* lib/thread.rb (Queue#pop): Fixed double registration issue when
Index: process.c
===================================================================
--- process.c	(revision 36939)
+++ process.c	(revision 36940)
@@ -1017,6 +1017,8 @@
 	 * On Mac OS X 10.5.x (Leopard) or earlier, exec() may return ENOTSUPP
 	 * if the process have multiple threads. Therefore we have to kill
 	 * internal threads temporary. [ruby-core:10583]
+	 * This is also true on Haiku. It returns Errno::EPERM against exec()
+	 * in multiple threads.
 	 */
 	rb_thread_stop_timer_thread(0);
     }
@@ -2307,7 +2309,7 @@
     rb_execarg_fixup(execarg_obj);
     fail_str = eargp->use_shell ? eargp->invoke.sh.shell_script : eargp->invoke.cmd.command_name;
 
-#ifdef __APPLE__
+#if defined(__APPLE__) || defined(__HAIKU__)
     rb_exec_without_timer_thread(eargp, errmsg, sizeof(errmsg));
 #else
     rb_exec_async_signal_safe(eargp, errmsg, sizeof(errmsg));

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]