Index: lib/ezwebdav/classes/ezwebdavfileserver.php =================================================================== --- lib/ezwebdav/classes/ezwebdavfileserver.php (revision 12429) +++ lib/ezwebdav/classes/ezwebdavfileserver.php (working copy) @@ -152,8 +152,8 @@ // Else, dir is available, do the thing: else { - // For all entires in the dir: - while ( $entry = readdir( $currentDir ) ) + // For all entries in the dir: + while ( false !== ( $entry = readdir( $currentDir ) ) ) { // If entry is a directory and not . && .. : if ( is_dir( "$dir/$entry" ) and @@ -472,7 +472,7 @@ $handle = opendir( $directory ); // For all the entries in the directory: - while ( $filename = readdir( $handle ) ) + while ( false !== ( $filename = readdir( $handle ) ) ) { // Skip current and parent dirs ('.' and '..'). if ( $filename == '.' or $filename == '..' )