174{
175 CONTEXT(
"NtObjDirectory::read_directory()");
176
179
182
184
186#ifndef UNICODE
188#endif
189
190 do {
192#ifndef UNICODE
194#endif
197#ifndef UNICODE
199#endif
200
203
204#ifdef UNICODE
206#else
208#endif
209 return;
210
211#ifdef UNICODE
214#else
217#endif
218
220
225
226 do {
228
229#ifdef UNICODE
230 if (
info->name.string_ptr) {
231 info->name.string_ptr[
info->name.string_len /
sizeof(
WCHAR)] = 0;
232 } else {
233 TCHAR empty_string_ptr[] =
_T(
"");
234 info->name.string_ptr = empty_string_ptr;
235 }
236 if (
info->type.string_ptr) {
237 info->type.string_ptr[
info->type.string_len /
sizeof(
WCHAR)] = 0;
238 } else {
239 TCHAR empty_string_ptr[] =
_T(
"");
240 info->type.string_ptr = empty_string_ptr;
241 }
243#else
245#endif
246
247 lstrcpyn(w32fd.cFileName,
p,
sizeof(w32fd.cFileName) /
sizeof(0[w32fd.cFileName]));
248
251
252 for(; *tname; tname++)
255
258
260 }
261
264
266
267#ifndef _NO_WIN_FS
268 if (*w32fd.cFileName>='A' &&*w32fd.cFileName<='Z' && w32fd.cFileName[1]==':')
273 }
274#endif
275
278 }
279
282
284 }
285 else
287
289
290#ifdef UNICODE
293#else
296#endif
297 {
300
302 memcpy(&w32fd.ftCreationTime, &
object.creation_time,
sizeof(
FILETIME));
303
305 entry->_bhfi.nNumberOfLinks =
object.reference_count - 1;
306 entry->_bhfi_valid =
true;
307 }
308
312
316#ifdef UNICODE
318#else
320#endif
322 }
323 }
324
326 }
327
329
330#ifdef UNICODE
332#else
333 char type_name[32];
336#endif
337
338 if (!first_entry)
340
343
345
348
350 }
351
353
356}
#define WideCharToMultiByte
#define ATTRIBUTE_SYMBOLIC_LINK
GLuint GLuint GLsizei GLenum type
GLubyte GLubyte GLubyte GLubyte w
#define memcpy(s1, s2, n)
#define wcsncpy_s(d, l, s, n)
#define FILE_ATTRIBUTE_DIRECTORY
static DWORD NtOpenObject(OBJECT_TYPE type, PHANDLE phandle, DWORD access, LPCWSTR path)
_Check_return_ _CRTIMP wchar_t *__cdecl _wcsdup(_In_z_ const wchar_t *_Str)
_Check_return_ _CRTIMP int __cdecl wcsncmp(_In_reads_or_z_(_MaxCount) const wchar_t *_Str1, _In_reads_or_z_(_MaxCount) const wchar_t *_Str2, _In_ size_t _MaxCount)
DynamicFct< DWORD(__stdcall *)(HANDLE, NtObjectInfo *, DWORD size, BOOL, BOOL, void *, void *)> NtQueryDirectoryObject
DynamicFct< DWORD(__stdcall *)(HANDLE)> NtClose
static const LPCWSTR s_ObjectTypes[]
DynamicFct< DWORD(__stdcall *)(HANDLE, DWORD, NtObject *, DWORD size, DWORD *read)> NtQueryObject
DynamicFct< DWORD(__stdcall *)(HANDLE, RtlUnicodeString *, DWORD *)> NtQuerySymbolicLinkObject
NtObj file system directory-entry.
Windows file system directory-entry.