Avoid warning messages when searching a directory without permissions
Avoid warning messages when searching a directory without permissions

Based on a fix by Justyn Shull

--- a/include/git/ProjectListDirectory.class.php
+++ b/include/git/ProjectListDirectory.class.php
@@ -91,7 +91,7 @@
 	 */
 	private function RecurseDir($dir)
 	{
-		if (!is_dir($dir))
+		if (!(is_dir($dir) && is_readable($dir)))
 			return;
 
 		GitPHP_Log::GetInstance()->Log(sprintf('Searching directory %1$s', $dir));

comments