lib/ohai/plugins/windows/filesystem.rb in ohai-0.6.4 vs lib/ohai/plugins/windows/filesystem.rb in ohai-0.6.6.rc.0

- old
+ new

@@ -27,10 +27,10 @@ disks.each do |disk| filesystem = disk.DeviceID fs[filesystem] = Mash.new ld_info[filesystem] = Mash.new disk.properties_.each do |p| - ld_info[filesystem][p.name.wmi_underscore.to_sym] = disk[p.name] + ld_info[filesystem][p.name.wmi_underscore.to_sym] = disk.send(p.name) end fs[filesystem][:kb_size] = ld_info[filesystem][:size].to_i / 1000 fs[filesystem][:kb_available] = ld_info[filesystem][:free_space].to_i / 1000 fs[filesystem][:kb_used] = fs[filesystem][:kb_size].to_i - fs[filesystem][:kb_available].to_i fs[filesystem][:percent_used] = (fs[filesystem][:kb_size].to_i != 0 ? fs[filesystem][:kb_used].to_i * 100 / fs[filesystem][:kb_size].to_i : 0)