mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-16 21:54:00 +02:00
make sure we always check for a valid directory handle
git-svn-id: file:///svn/phpbb/trunk@8211 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -89,15 +89,17 @@ class acp_icons
|
||||
}
|
||||
unset($imglist);
|
||||
|
||||
$dir = @opendir($phpbb_root_path . $img_path);
|
||||
while (($file = @readdir($dir)) !== false)
|
||||
if ($dir = @opendir($phpbb_root_path . $img_path))
|
||||
{
|
||||
if (is_file($phpbb_root_path . $img_path . '/' . $file) && preg_match('#\.pak$#i', $file))
|
||||
while (($file = readdir($dir)) !== false)
|
||||
{
|
||||
$_paks[] = $file;
|
||||
if (is_file($phpbb_root_path . $img_path . '/' . $file) && preg_match('#\.pak$#i', $file))
|
||||
{
|
||||
$_paks[] = $file;
|
||||
}
|
||||
}
|
||||
closedir($dir);
|
||||
}
|
||||
@closedir($dir);
|
||||
}
|
||||
|
||||
// What shall we do today? Oops, I believe that's trademarked ...
|
||||
|
Reference in New Issue
Block a user