summaryrefslogtreecommitdiff
path: root/thread.c
diff options
context:
space:
mode:
authornagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-09-12 17:11:50 +0000
committernagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-09-12 17:11:50 +0000
commita6929d1d7e276184427d861797fff8cc7e9badb6 (patch)
treee27ae851e49e76b1d28e6a9385f30183502cfdf3 /thread.c
parentacdfd915207669e847940cc6a10be3b7218c7857 (diff)
merge revision(s) 42906: [Backport #8891]
* thread.c (rb_mutex_unlock): Mutex#unlock no longer raise an exception even if uses on trap. [Bug #8891] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@42926 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread.c')
-rw-r--r--thread.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/thread.c b/thread.c
index 4c5a5e97a5..b2ec68a623 100644
--- a/thread.c
+++ b/thread.c
@@ -4425,11 +4425,6 @@ rb_mutex_unlock(VALUE self)
rb_mutex_t *mutex;
GetMutexPtr(self, mutex);
- /* When running trap handler */
- if (!mutex->allow_trap && GET_THREAD()->interrupt_mask & TRAP_INTERRUPT_MASK) {
- rb_raise(rb_eThreadError, "can't be called from trap context");
- }
-
err = rb_mutex_unlock_th(mutex, GET_THREAD());
if (err) rb_raise(rb_eThreadError, "%s", err);