From 9242da9e02fb7b37e20d6178ba6c9658d6bf8f31 Mon Sep 17 00:00:00 2001 From: nobu Date: Fri, 10 Aug 2007 14:54:50 +0000 Subject: * thread.c (thread_create_core): inherit the priority of creating thread. submitted at [ruby-core:11873] by David Flanagan . [ruby-core:11876] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12915 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- thread.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'thread.c') diff --git a/thread.c b/thread.c index f5c2773599..301d67137a 100644 --- a/thread.c +++ b/thread.c @@ -367,6 +367,8 @@ thread_create_core(VALUE klass, VALUE args, VALUE (*fn)(ANYARGS), void *arg) th->first_func = fn; th->first_func_arg = arg; + th->priority = GET_THREAD()->priority; + native_mutex_initialize(&th->interrupt_lock); /* kick thread */ st_insert(th->vm->living_threads, thval, (st_data_t) th->thread_id); -- cgit v1.2.3