Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
1.1 KiB

  1. #include <stdinc.h>
  2. BOOL
  3. W32::GetFileAttributesExW(
  4. PCWSTR lpFileName,
  5. GET_FILEEX_INFO_LEVELS fInfoLevelId,
  6. LPVOID lpFileInformation,
  7. DWORD &rdwWin32Error,
  8. ULONG cELEV,
  9. va_list ap
  10. )
  11. {
  12. rdwWin32Error = ERROR_SUCCESS;
  13. BOOL fSuccess = ::GetFileAttributesExW(lpFileName, fInfoLevelId, lpFileInformation);
  14. if ((!fSuccess) && (cELEV != 0))
  15. {
  16. if (::IsLastErrorInList(cELEV, ap, rdwWin32Error))
  17. fSuccess = TRUE;
  18. }
  19. return fSuccess;
  20. }
  21. BOOL
  22. W32::GetFileAttributesExW(
  23. PCWSTR lpFileName,
  24. GET_FILEEX_INFO_LEVELS fInfoLevelId,
  25. LPVOID lpFileInformation,
  26. DWORD &rdwWin32Error,
  27. ULONG cELEV,
  28. ...
  29. )
  30. {
  31. BOOL f;
  32. va_list ap;
  33. va_start(ap, cELEV);
  34. f = W32::GetFileAttributesExW(lpFileName, fInfoLevelId, lpFileInformation, rdwWin32Error, cELEV, ap);
  35. va_end(ap);
  36. return f;
  37. }
  38. BOOL
  39. W32::GetFileAttributesExW(
  40. PCWSTR lpFileName,
  41. GET_FILEEX_INFO_LEVELS fInfoLevelId,
  42. LPVOID lpFileInformation
  43. )
  44. {
  45. DWORD x;
  46. return W32::GetFileAttributesExW(lpFileName, fInfoLevelId, lpFileInformation, x, 0);
  47. }