tst: ntptfs: NtQueryDirectoryFile workaround comment

This commit is contained in:
Bill Zissimopoulos 2022-01-26 09:18:16 +00:00
parent f7ba091364
commit 172056b51e
No known key found for this signature in database
GPG Key ID: 3D4F95D52C7B3EA3

View File

@ -162,8 +162,11 @@ static NTSTATUS CreateEx(FSP_FILE_SYSTEM *FileSystem,
/* WORKAROUND: /* WORKAROUND:
* *
* WOW64 appears to have a bug in some versions of the OS, where NtQueryDirectoryFile may fail * WOW64 appears to have a bug in some versions of the OS (seen on Win10 1909 and
* if called on a directory that has been opened without FILE_SYNCHRONOUS_IO_NONALERT. * Server 2012 R2), where NtQueryDirectoryFile may produce garbage if called on a
* directory that has been opened without FILE_SYNCHRONOUS_IO_NONALERT. (Garbage:
* after a STATUS_PENDING has been waited, Iosb.Information reports bytes transferred
* but the buffer does not get filled).
* *
* So make sure to always open directories in a synchronous manner. * So make sure to always open directories in a synchronous manner.
*/ */
@ -273,8 +276,11 @@ static NTSTATUS Open(FSP_FILE_SYSTEM *FileSystem,
/* WORKAROUND: /* WORKAROUND:
* *
* WOW64 appears to have a bug in some versions of the OS, where NtQueryDirectoryFile may fail * WOW64 appears to have a bug in some versions of the OS (seen on Win10 1909 and
* if called on a directory that has been opened without FILE_SYNCHRONOUS_IO_NONALERT. * Server 2012 R2), where NtQueryDirectoryFile may produce garbage if called on a
* directory that has been opened without FILE_SYNCHRONOUS_IO_NONALERT. (Garbage:
* after a STATUS_PENDING has been waited, Iosb.Information reports bytes transferred
* but the buffer does not get filled).
* *
* So make sure to always open directories in a synchronous manner. * So make sure to always open directories in a synchronous manner.
*/ */