]> source.dussan.org Git - redmine.git/commitdiff
Fix that binmode specified twice (#35539, #35720).
authorGo MAEDA <maeda@farend.jp>
Wed, 18 Aug 2021 02:34:46 +0000 (02:34 +0000)
committerGo MAEDA <maeda@farend.jp>
Wed, 18 Aug 2021 02:34:46 +0000 (02:34 +0000)
Patch by Pavel Rosický.

git-svn-id: http://svn.redmine.org/redmine/trunk@21193 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/models/attachment.rb

index c65c5672203d7ca5a3e35bffc7639a6bb9380375..8fba26effc2156b5604dbfd1ad8fa209eb6b3415 100644 (file)
@@ -571,7 +571,7 @@ class Attachment < ActiveRecord::Base
         name = "#{timestamp}_#{ascii}"
         File.open(
           File.join(path, name),
-          flags: File::CREAT | File::EXCL | File::BINARY | File::WRONLY,
+          flags: File::CREAT | File::EXCL | File::WRONLY,
           binmode: true,
           &block
         )