Permalink
Browse files

Ignoring invalid byte sequence exceptions

  • Loading branch information...
itsderek23 committed Oct 3, 2011
1 parent 6fca410 commit ae90ed27b116bd8c73093bbcdc092e3f34b8f526
Showing with 4 additions and 1 deletion.
  1. +4 −1 passenger_memory_stats/passenger_memory_stats.rb
@@ -24,7 +24,10 @@ def build_report
remember(mem_name => memory(mem_name))
end
end
- else
+ # The following exception will occassially be raised by passenger-memory-stats:
+ # /usr/local/rvm/gems/ruby-1.9.2-p136/gems/passenger-3.0.2/lib/phusion_passenger/admin_tools/memory_stats.rb:247:in `split': invalid byte sequence in US-ASCII (ArgumentError)
+ # This will ignore that error.
+ elsif data !~ /invalid byte sequence/
error "Could not get data from command", "Error: #{data}"
end
end

0 comments on commit ae90ed2

Please sign in to comment.