diff options
Diffstat (limited to 'dir.c')
-rw-r--r-- | dir.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -1064,8 +1064,10 @@ dir_s_chdir(int argc, VALUE *argv, VALUE obj) } if (chdir_blocking > 0) { - if (!rb_block_given_p() || rb_thread_current() != chdir_thread) + if (rb_thread_current() != chdir_thread) rb_raise(rb_eRuntimeError, "conflicting chdir during another chdir block"); + if (!rb_block_given_p()) + rb_warn("conflicting chdir during another chdir block"); } if (rb_block_given_p()) { |