diff --git a/wp-includes/functions.php b/wp-includes/functions.php index e8391dca4d..8328fcfc85 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -1541,7 +1541,7 @@ function get_themes() { $themes_dir = @ dir($theme_root); if ($themes_dir) { while(($theme_dir = $themes_dir->read()) !== false) { - if (is_dir($theme_root . '/' . $theme_dir)) { + if ( is_dir($theme_root . '/' . $theme_dir) && is_readable($theme_root . '/' . $theme_dir) ) { if ($theme_dir{0} == '.' || $theme_dir == '..' || $theme_dir == 'CVS') { continue; }