diff options
author | Ken Barber <ken@bob.sh> | 2012-02-06 17:55:43 +0000 |
---|---|---|
committer | Ken Barber <ken@bob.sh> | 2012-02-06 17:55:43 +0000 |
commit | 52bc8809cbdedbacf219289df1f9f48056e6b935 (patch) | |
tree | 047de98a042a38e6dfe6d3915246a5e0634f33cc /lib | |
parent | 4c2bba86f81695023cec68bfe112591cfeec7c80 (diff) | |
parent | 24f7095e282fc364b9d12ff26c268b4fd919f09c (diff) | |
download | puppet-stdlib-52bc8809cbdedbacf219289df1f9f48056e6b935.tar.gz puppet-stdlib-52bc8809cbdedbacf219289df1f9f48056e6b935.tar.bz2 |
Merge branch 'ticket/2.2.x/12377_stdlib_facter_dot_d_loaderror_recovery_may_be_harmful' into 2.1.x
* ticket/2.2.x/12377_stdlib_facter_dot_d_loaderror_recovery_may_be_harmful:
(#12377) Avoid infinite loop when retrying require json
Diffstat (limited to 'lib')
-rw-r--r-- | lib/facter/facter_dot_d.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/facter/facter_dot_d.rb b/lib/facter/facter_dot_d.rb index 90586a9..2658dfe 100644 --- a/lib/facter/facter_dot_d.rb +++ b/lib/facter/facter_dot_d.rb @@ -54,8 +54,8 @@ class Facter::Util::DotD begin require 'json' rescue LoadError - require 'rubygems' - retry + retry if require 'rubygems' + raise end JSON.load(File.read(file)).each_pair do |f, v| |