Skip to content

Commit 5ba1d0b

Browse files
authored
Detect RbConfig::CONFIG["target_os"] == "darwin20"
Reported by macOs Big Sur 11.4.
1 parent 0cca522 commit 5ba1d0b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/concurrent-ruby/concurrent/utility/processor_counter.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ def compute_processor_count
119119

120120
def compute_physical_processor_count
121121
ppc = case RbConfig::CONFIG["target_os"]
122-
when /darwin1/
122+
when /darwin\d\d/
123123
IO.popen("/usr/sbin/sysctl -n hw.physicalcpu", &:read).to_i
124124
when /linux/
125125
cores = {} # unique physical ID / core ID combinations

0 commit comments

Comments
 (0)