summaryrefslogtreecommitdiff
path: root/lib/rubygems/core_ext
diff options
context:
space:
mode:
authorKoichi Sasada <ko1@atdot.net>2019-11-12 04:03:33 +0900
committerKoichi Sasada <ko1@atdot.net>2019-11-12 04:03:33 +0900
commita815053a3ea16382bea8b420a3070b4da3c3bb94 (patch)
tree5f1150d2a6f0d7973f92462e5edc0b5c4b8f1335 /lib/rubygems/core_ext
parent99be207c2acabe0030c376fd731608d9cd7c69b6 (diff)
check monitor is owning for debug
Diffstat (limited to 'lib/rubygems/core_ext')
-rw-r--r--lib/rubygems/core_ext/kernel_require.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/rubygems/core_ext/kernel_require.rb b/lib/rubygems/core_ext/kernel_require.rb
index f0409d6..dfceb75 100644
--- a/lib/rubygems/core_ext/kernel_require.rb
+++ b/lib/rubygems/core_ext/kernel_require.rb
@@ -157,6 +157,11 @@ module Kernel
return gem_original_require(path) if require_again
raise load_error
+ ensure
+ if RUBYGEMS_ACTIVATION_MONITOR.mon_owned?
+ pp $!
+ raise "CRITICAL: RUBYGEMS_ACTIVATION_MONITOR is holding."
+ end
end
private :require