diff options
author | ytti <saku@ytti.fi> | 2017-01-09 23:43:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-09 23:43:40 +0200 |
commit | 131adcc429e09da969284fda48a319625533ef80 (patch) | |
tree | 298d2badc708014a7c9a467475cc2591a4a8edf6 /lib/oxidized/model/ironware.rb | |
parent | 8b980c327adc0f92867ab2c44037543aa46b3c5f (diff) | |
parent | 853a1dd57776955c20377f6f13a5a71e892d89f0 (diff) |
Merge pull request #659 from devicenull/patch-1
Ignore undefined UTF8 in ironware.rb
Diffstat (limited to 'lib/oxidized/model/ironware.rb')
-rw-r--r-- | lib/oxidized/model/ironware.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/oxidized/model/ironware.rb b/lib/oxidized/model/ironware.rb index db341d1..ade8b44 100644 --- a/lib/oxidized/model/ironware.rb +++ b/lib/oxidized/model/ironware.rb @@ -30,7 +30,7 @@ class IronWare < Oxidized::Model end cmd 'show chassis' do |cfg| - cfg.encode!("UTF-8", :invalid => :replace) #sometimes ironware returns broken encoding + cfg.encode!("UTF-8", :invalid => :replace, :undef => :replace) #sometimes ironware returns broken encoding cfg.gsub! /(^((.*)Current temp(.*))$)/, '' #remove unwanted lines current temperature cfg.gsub! /Speed = [A-Z-]{2,6} \(\d{2,3}\%\)/, '' #remove unwanted lines Speed Fans cfg.gsub! /current speed is [A-Z]{2,6} \(\d{2,3}\%\)/, '' |