Skip to content

Commit

Permalink
Merge pull request #5179 from RalphShnelvar/Binary_mode_Window_bug
Browse files Browse the repository at this point in the history
Binary mode window bug
  • Loading branch information
tenderlove committed Feb 27, 2012
1 parent 5c18b99 commit 47c3cf1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion activesupport/lib/active_support/core_ext/file/atomic.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def self.atomic_write(file_name, temp_dir = Dir.tmpdir)
require 'tempfile' unless defined?(Tempfile)
require 'fileutils' unless defined?(FileUtils)

temp_file = Tempfile.new(basename(file_name), temp_dir)
temp_file = Tempfile.new(basename(file_name), temp_dir, :binmode => true)
yield temp_file
temp_file.close

Expand Down

0 comments on commit 47c3cf1

Please sign in to comment.