From 59e87d0e1ebb477735b9c63f54c6ae5436cfd334 Mon Sep 17 00:00:00 2001 From: root Date: Wed, 17 Jun 2015 12:18:37 +0200 Subject: fix regexp error with ruby 2.1 --- lib/oxidized/model/ironware.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/oxidized') diff --git a/lib/oxidized/model/ironware.rb b/lib/oxidized/model/ironware.rb index 1ec8b80..83af5a1 100644 --- a/lib/oxidized/model/ironware.rb +++ b/lib/oxidized/model/ironware.rb @@ -32,7 +32,7 @@ class IronWare < Oxidized::Model end cmd 'show chassis' do |cfg| - cfg.gsub! "\xFF", '' # ugly hack - avoids JSON.dump utf-8 breakage on 1.9.. + cfg.gsub! /\xFF/n, '' # ugly hack - avoids JSON.dump utf-8 breakage on 1.9.. cfg.gsub! /(^((.*)Current temp(.*))$)/, '' #remove unwanted lines current temperature cfg.gsub! /Speed = [A-Z]{3} \(\d{2}\%\)/, '' #remove unwanted lines Speed Fans cfg.gsub! /current speed is [A-Z]{3} \(\d{2}\%\)/, '' -- cgit v1.2.1