mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
[ticket/13814] Prevent phpbb_is_writable() method from truncating files
phpbb_is_writable() of filesystem class uses 'w' mode to fopen files which causes checked files to be truncated. Use the 'c' mode instead. PHPBB3-13814
This commit is contained in:
@@ -613,7 +613,7 @@ class filesystem implements filesystem_interface
|
||||
}
|
||||
else
|
||||
{
|
||||
$handle = @fopen($file, 'w');
|
||||
$handle = @fopen($file, 'c');
|
||||
|
||||
if (is_resource($handle))
|
||||
{
|
||||
|
Reference in New Issue
Block a user