diff options
author | knu <knu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-02-26 18:41:08 +0000 |
---|---|---|
committer | knu <knu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-02-26 18:41:08 +0000 |
commit | 3bcf72a28cb82a8d3ff05202f2c1e269261ae6aa (patch) | |
tree | 62e64ff46d128d57a8cdcb3a2e3841a41e833e70 /ext/thread | |
parent | e529cb40d072d08362f3ee68181929e671b9510e (diff) |
* ext/thread/thread.c: Consistently use 0 and 1 for
rb_thread_critical values.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@11893 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/thread')
-rw-r--r-- | ext/thread/thread.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/thread/thread.c b/ext/thread/thread.c index 64215dca72..bf84a390c6 100644 --- a/ext/thread/thread.c +++ b/ext/thread/thread.c @@ -21,7 +21,7 @@ static VALUE rb_cSizedQueue; static VALUE thread_exclusive_do() { - rb_thread_critical = Qtrue; + rb_thread_critical = 1; return rb_yield(Qundef); } @@ -639,11 +639,11 @@ wait_condvar(ConditionVariable *condvar, Mutex *mutex) { rb_thread_critical = 1; if (!RTEST(mutex->owner)) { - rb_thread_critical = Qfalse; + rb_thread_critical = 0; return; } if (mutex->owner != rb_thread_current()) { - rb_thread_critical = Qfalse; + rb_thread_critical = 0; rb_raise(rb_eThreadError, "Not owner"); } mutex->owner = Qnil; |