summaryrefslogtreecommitdiff
path: root/thread.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-11-08 15:31:05 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-11-08 15:31:05 +0000
commit641f43de973d51a7d463b067833d4a71706d6c5c (patch)
tree555a72d40d2a2645020a675fc085b716dd097f2b /thread.c
parentb2390fb1cc3f38ca4516394034c8680eeb01a64c (diff)
* thread_pthread.c (thread_timer): checks working flags again.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20160 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread.c')
-rw-r--r--thread.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/thread.c b/thread.c
index ca47419644..f6bcc9801f 100644
--- a/thread.c
+++ b/thread.c
@@ -75,6 +75,7 @@ void rb_thread_stop_timer_thread(void);
static const VALUE eKillSignal = INT2FIX(0);
static const VALUE eTerminateSignal = INT2FIX(1);
+static volatile int system_working = 1;
inline static void
st_delete_wrap(st_table *table, st_data_t key)
@@ -2355,8 +2356,7 @@ timer_thread_function(void *arg)
void
rb_thread_stop_timer_thread(void)
{
- if (timer_thread_id) {
- native_stop_timer_thread();
+ if (timer_thread_id && native_stop_timer_thread()) {
native_thread_join(timer_thread_id);
timer_thread_id = 0;
}