diff options
author | kosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-03-19 18:26:11 +0000 |
---|---|---|
committer | kosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-03-19 18:26:11 +0000 |
commit | c9073822c2837bc51d47f1b90e2dae0701c08281 (patch) | |
tree | 67e3f2265b9d9f1dfe59f4d4bced98b2ecd5cf63 /thread.c | |
parent | d617690a65f82eeb82c8bdb1bec8f07be8f8979e (diff) | |
download | ruby-c9073822c2837bc51d47f1b90e2dae0701c08281.tar.gz |
* thread.c (ruby_kill): release GVL while waiting signal delivered.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39826 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread.c')
-rw-r--r-- | thread.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -5211,10 +5211,12 @@ ruby_kill(rb_pid_t pid, int sig) rb_vm_t *vm = GET_VM(); if ((th == vm->main_thread) && (pid == getpid())) { + GVL_UNLOCK_BEGIN(); native_mutex_lock(&th->interrupt_lock); err = kill(pid, sig); native_cond_wait(&th->interrupt_cond, &th->interrupt_lock); native_mutex_unlock(&th->interrupt_lock); + GVL_UNLOCK_END(); } else { err = kill(pid, sig); } |