diff options
author | Joshua M. Keyes <joshua.michael.keyes@gmail.com> | 2017-09-06 14:31:08 -0700 |
---|---|---|
committer | Joshua M. Keyes <joshua.michael.keyes@gmail.com> | 2017-09-06 14:31:08 -0700 |
commit | c54d076bbaca77f6144bd978ca3198cbdb715c8c (patch) | |
tree | 233420313351d509b9c5391bc2d093479ff24932 | |
parent | a4174019e55992182a357573022a8ce024284bf7 (diff) |
Fix encoding error from FTOS while listing hardware inventory on old firmware versions.
-rw-r--r-- | lib/oxidized/model/ftos.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/oxidized/model/ftos.rb b/lib/oxidized/model/ftos.rb index b465271..1c3b8b4 100644 --- a/lib/oxidized/model/ftos.rb +++ b/lib/oxidized/model/ftos.rb @@ -15,6 +15,8 @@ class FTOS < Oxidized::Model end cmd 'show inventory' do |cfg| + # Old versions of FTOS can occasionally return data that triggers encoding errors. + cfg.encode!("UTF-8", :invalid => :replace, :undef => :replace, :replace => "") comment cfg end |