diff --git a/phpBB/phpbb/files/filespec_storage.php b/phpBB/phpbb/files/filespec_storage.php index b4042ebf10..c39c47dc38 100644 --- a/phpBB/phpbb/files/filespec_storage.php +++ b/phpBB/phpbb/files/filespec_storage.php @@ -447,7 +447,9 @@ class filespec_storage try { - $storage->put_contents($this->destination_file, file_get_contents($this->filename)); + $fp = fopen($this->filename, 'rb'); + $storage->write_stream($this->destination_file, $fp); + fclose($fp); } catch (\phpbb\storage\exception\exception $e) {