mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
[rubygems/rubygems] Restrict flock
to Windows
It was introduced to fix some race conditions there, but it doesn't seem
necessary on other systems and it's actually causing issues there.
27b682c812
This commit is contained in:
parent
71bc999009
commit
ec5bde1a80
1 changed files with 1 additions and 1 deletions
|
@ -781,7 +781,7 @@ An Array (#{env.inspect}) was passed in from #{caller[3]}
|
|||
|
||||
def self.open_with_flock(path, flags, &block)
|
||||
File.open(path, flags) do |io|
|
||||
if !java_platform? && !solaris_platform?
|
||||
if !java_platform? && win_platform?
|
||||
begin
|
||||
io.flock(File::LOCK_EX)
|
||||
rescue Errno::ENOSYS, Errno::ENOTSUP
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue