Ken Thomases : ntdll: If read_directory_getattrlist() finds that the file doesn't exist, return successful "no file" result to stop search.

Alexandre Julliard julliard at wine.codeweavers.com
Thu May 21 07:24:22 CDT 2015


Module: wine
Branch: master
Commit: 5c98448aa3acb9bac40a0afa28ffbee3001081d0
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=5c98448aa3acb9bac40a0afa28ffbee3001081d0

Author: Ken Thomases <ken at codeweavers.com>
Date:   Wed May 20 14:59:11 2015 -0500

ntdll: If read_directory_getattrlist() finds that the file doesn't exist, return successful "no file" result to stop search.

---

 dlls/ntdll/directory.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/dlls/ntdll/directory.c b/dlls/ntdll/directory.c
index 0e5af8a..267f019 100644
--- a/dlls/ntdll/directory.c
+++ b/dlls/ntdll/directory.c
@@ -2185,6 +2185,11 @@ static int read_directory_getattrlist( int fd, IO_STATUS_BLOCK *io, void *buffer
             }
             else io->u.Status = STATUS_NO_MORE_FILES;
         }
+        else if ((errno == ENOENT || errno == ENOTDIR) && !get_dir_case_sensitivity("."))
+        {
+            io->u.Status = STATUS_NO_MORE_FILES;
+            ret = 0;
+        }
     }
     else ret = -1;
 




More information about the wine-cvs mailing list