summaryrefslogtreecommitdiff
path: root/tool
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2023-03-28 00:41:08 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2023-03-28 17:17:51 +0900
commitf6adc5be94a9f70a5b9897b81dabdeb49b573393 (patch)
tree69a9ec99bf2ef8e3209012426fc719af5ac7d0f5 /tool
parenta136ca0d042deed6d6db1aaf5740a05772c1e152 (diff)
downloadruby-f6adc5be94a9f70a5b9897b81dabdeb49b573393.tar.gz
Check if Bundler is defined
Diffstat (limited to 'tool')
-rw-r--r--tool/lib/leakchecker.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/tool/lib/leakchecker.rb b/tool/lib/leakchecker.rb
index 1966145588..ea07049aa5 100644
--- a/tool/lib/leakchecker.rb
+++ b/tool/lib/leakchecker.rb
@@ -235,7 +235,7 @@ class LeakChecker
return false if old_env == new_env
(old_env.keys | new_env.keys).sort.each {|k|
# Don't report changed environment variables caused by Bundler's backups
- next if k.start_with?(Bundler::EnvironmentPreserver::BUNDLER_PREFIX)
+ next if defined?(Bundler) and k.start_with?(Bundler::EnvironmentPreserver::BUNDLER_PREFIX)
if old_env.has_key?(k)
if new_env.has_key?(k)