Permalink
Browse files

[Filesystem] Changed the mode for a target file in copy() to be write…

… only.

Stream wrappers like S3 do not support w+.
  • Loading branch information...
1 parent 07c705b commit 689df2a6d479bd20a58c946086e07c9887c56768 @jakzal jakzal committed Dec 16, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 Filesystem.php
View
@@ -50,7 +50,7 @@ public function copy($originFile, $targetFile, $override = false)
if ($doCopy) {
// https://bugs.php.net/bug.php?id=64634
$source = fopen($originFile, 'r');
- $target = fopen($targetFile, 'w+');
+ $target = fopen($targetFile, 'w');
stream_copy_to_stream($source, $target);
fclose($source);
fclose($target);

0 comments on commit 689df2a

Please sign in to comment.