Skip to content

Commit 5fd3040

Browse files
authored
Merge pull request #917 from donv/patch-1
Detect RbConfig::CONFIG["target_os"] == "darwin20"
2 parents 0cca522 + 5ba1d0b commit 5fd3040

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)