lib/celluloid/cpu_counter.rb in celluloid-0.13.0 vs lib/celluloid/cpu_counter.rb in celluloid-0.14.0.pre

- old
+ new

@@ -10,10 +10,10 @@ File.read("/sys/devices/system/cpu/present").split('-').last.to_i+1 else Dir["/sys/devices/system/cpu/cpu*"].select { |n| n=~/cpu\d+/ }.count end when 'mingw', 'mswin' - @cores = Integer(`SET NUMBER_OF_PROCESSORS`[/\d+/]) + @cores = Integer(ENV["NUMBER_OF_PROCESSORS"][/\d+/]) else @cores = nil end def self.cores; @cores; end