Skip to content

Commit

Permalink
ruby: remove upstreamed patch
Browse files Browse the repository at this point in the history
  • Loading branch information
mistydemeo committed Mar 21, 2014
1 parent cce728b commit 7f52b2d
Showing 1 changed file with 0 additions and 37 deletions.
37 changes: 0 additions & 37 deletions Formula/ruby.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,6 @@ class Ruby < Formula
build 2326
end

# pthread_setname_np() is unavailable before Snow Leopard
# Reported upstream: https://bugs.ruby-lang.org/issues/9492
patch :DATA if MacOS.version < :snow_leopard

def install
system "autoconf" if build.head?

Expand Down Expand Up @@ -85,36 +81,3 @@ def caveats; <<-EOS.undent
assert_equal 0, $?.exitstatus
end
end

__END__
diff --git a/thread_pthread.c b/thread_pthread.c
index 3911f8f..74d1ab7 100644
--- a/thread_pthread.c
+++ b/thread_pthread.c
@@ -1416,15 +1416,6 @@ timer_thread_sleep(rb_global_vm_lock_t* unused)
}
#endif /* USE_SLEEPY_TIMER_THREAD */

-#if defined(__linux__) && defined(PR_SET_NAME)
-# define SET_THREAD_NAME(name) prctl(PR_SET_NAME, name)
-#elif defined(__APPLE__)
-/* pthread_setname_np() on Darwin does not have target thread argument */
-# define SET_THREAD_NAME(name) pthread_setname_np(name)
-#else
-# define SET_THREAD_NAME(name) (void)0
-#endif
-
static void *
thread_timer(void *p)
{
@@ -1432,7 +1423,9 @@ thread_timer(void *p)

if (TT_DEBUG) WRITE_CONST(2, "start timer thread\n");

- SET_THREAD_NAME("ruby-timer-thr");
+#if defined(__linux__) && defined(PR_SET_NAME)
+ prctl(PR_SET_NAME, "ruby-timer-thr");
+#endif

#if !USE_SLEEPY_TIMER_THREAD
native_mutex_initialize(&timer_thread_lock);

0 comments on commit 7f52b2d

Please sign in to comment.