[ticket/17361] Remove fclose after write

PHPBB-17361
This commit is contained in:
Ruben Calvo 2024-11-28 21:21:15 +01:00
parent e9c445925b
commit 6d9a8ae8af
No known key found for this signature in database
3 changed files with 0 additions and 15 deletions

View file

@ -246,11 +246,6 @@ class upload
$fp = fopen($destination, 'rb'); $fp = fopen($destination, 'rb');
$this->storage->write($destination_name, $fp); $this->storage->write($destination_name, $fp);
if (is_resource($fp))
{
fclose($fp);
}
} }
else else
{ {

View file

@ -447,11 +447,6 @@ class filespec_storage
$fp = fopen($this->filename, 'rb'); $fp = fopen($this->filename, 'rb');
$storage->write($this->destination_file, $fp); $storage->write($this->destination_file, $fp);
if (is_resource($fp))
{
fclose($fp);
}
} }
catch (\phpbb\storage\exception\storage_exception $e) catch (\phpbb\storage\exception\storage_exception $e)
{ {

View file

@ -195,11 +195,6 @@ class helper
$stream = $current_adapter->read($file); $stream = $current_adapter->read($file);
$new_adapter->write($file, $stream); $new_adapter->write($file, $stream);
if (is_resource($stream))
{
fclose($stream);
}
} }