diff options
author | Joel Nimety <jnimety@continuity.net> | 2011-02-15 14:21:33 -0500 |
---|---|---|
committer | Santiago Pastorino <santiago@wyeworks.com> | 2011-02-15 20:13:06 -0200 |
commit | ef573342106369b07bb5c97a0db0b121d6d18621 (patch) | |
tree | 849b956153d7e419af40440657aa2c17c13be3a5 /activesupport/lib | |
parent | 09ccdc3737144e21f090ab658b160b91e1a4a691 (diff) | |
download | rails-ef573342106369b07bb5c97a0db0b121d6d18621.tar.gz rails-ef573342106369b07bb5c97a0db0b121d6d18621.tar.bz2 rails-ef573342106369b07bb5c97a0db0b121d6d18621.zip |
GcTime incorrectly checks GC.respond_to?(:total_time), it should check GC::Profiler.respond_to?(:total_time)
[#6435 state:committed]
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
Diffstat (limited to 'activesupport/lib')
-rw-r--r-- | activesupport/lib/active_support/testing/performance.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/testing/performance.rb b/activesupport/lib/active_support/testing/performance.rb index 64b436ba8c..8c91a061fb 100644 --- a/activesupport/lib/active_support/testing/performance.rb +++ b/activesupport/lib/active_support/testing/performance.rb @@ -401,7 +401,7 @@ begin Mode = RubyProf::GC_TIME if RubyProf.const_defined?(:GC_TIME) # Ruby 1.9 with GC::Profiler - if GC.respond_to?(:total_time) + if defined?(GC::Profiler) && GC::Profiler.respond_to?(:total_time) def measure GC::Profiler.total_time end |