eric pouech (@epo) commented about dlls/ntdll/tests/directory.c:
+ test_NtQueryDirectoryFile_mask(dirh, TRUE, &emptymask, STATUS_NO_MORE_FILES, FALSE, FALSE); + test_NtQueryDirectoryFile_mask(dirh, FALSE, &emptymask, STATUS_NO_MORE_FILES, FALSE, FALSE); + + /* Test empty mask with a previously used handle that last returned STATUS_SUCCESS */ + test_NtQueryDirectoryFile_mask(dirh, TRUE, &testmask, STATUS_SUCCESS, FALSE, TRUE); + test_NtQueryDirectoryFile_mask(dirh, TRUE, &emptymask, STATUS_SUCCESS, FALSE, FALSE); + test_NtQueryDirectoryFile_mask(dirh, FALSE, &emptymask, STATUS_SUCCESS, FALSE, FALSE); + + /* Test empty mask with a fresh handle */ + test_NtQueryDirectoryFile_mask(dirh_test_fresh_empty, TRUE, &emptymask, STATUS_SUCCESS, FALSE, FALSE); + test_NtQueryDirectoryFile_mask(dirh_test_fresh_empty, FALSE, &emptymask, STATUS_SUCCESS, FALSE, FALSE); + + /* Cleanup */ +done: + tear_down_mask_test(testdir); + pRtlFreeUnicodeString(&ntdirname); RtlInitUnicodeString doesn't allocate any memory, so UNICODE_STRING shouldn't be freed
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/6904#note_92918