ntdll: Don't bother to check the file name against the mask if stat() succeeded.

This commit is contained in:
Alexandre Julliard 2008-06-30 15:10:50 +02:00
parent d45677788e
commit d350998cec
1 changed files with 2 additions and 1 deletions

View File

@ -1508,7 +1508,7 @@ static int read_directory_stat( int fd, IO_STATUS_BLOCK *io, void *buffer, ULONG
ret = stat( unix_name, &st );
if (!ret)
{
FILE_BOTH_DIR_INFORMATION *info = append_entry( buffer, &io->Information, length, unix_name, NULL, mask );
FILE_BOTH_DIR_INFORMATION *info = append_entry( buffer, &io->Information, length, unix_name, NULL, NULL );
if (info)
{
info->NextEntryOffset = 0;
@ -1517,6 +1517,7 @@ static int read_directory_stat( int fd, IO_STATUS_BLOCK *io, void *buffer, ULONG
else
lseek( fd, 1, SEEK_CUR );
}
else io->u.Status = STATUS_NO_MORE_FILES;
}
}
else ret = -1;