ruby-changes:57127
From: Hiroshi <ko1@a...>
Date: Sat, 17 Aug 2019 15:22:26 +0900 (JST)
Subject: [ruby-changes:57127] Hiroshi SHIBATA: 260ef51a73 (master): `Gem.load_path_insert_index always returns non-nil index after Ruby 1.9
https://git.ruby-lang.org/ruby.git/commit/?id=260ef51a73 From 260ef51a73c067599826c8ab110c53994c1b6226 Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA <hsbt@r...> Date: Sat, 17 Aug 2019 12:33:38 +0900 Subject: `Gem.load_path_insert_index always returns non-nil index after Ruby 1.9 diff --git a/lib/rubygems/core_ext/kernel_require.rb b/lib/rubygems/core_ext/kernel_require.rb index d121d82..cc7ec7e 100755 --- a/lib/rubygems/core_ext/kernel_require.rb +++ b/lib/rubygems/core_ext/kernel_require.rb @@ -38,7 +38,7 @@ module Kernel https://github.com/ruby/ruby/blob/trunk/lib/rubygems/core_ext/kernel_require.rb#L38 resolved_path = begin rp = nil - $LOAD_PATH[0...Gem.load_path_insert_index || -1].each do |lp| + $LOAD_PATH[0...Gem.load_path_insert_index].each do |lp| safe_lp = lp.dup.untaint next if File.symlink? safe_lp Gem.suffixes.each do |s| -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/