Leaked source code of windows server 2003
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.

36 lines
1.1 KiB

  1. #pragma once
  2. //
  3. // Define result codes.
  4. //
  5. #define SUCCESS 0
  6. #define FAILURE 1
  7. //
  8. // Define helper macro to deal with subtleties of NT-level programming.
  9. //
  10. #define INIT_OBJA(Obja,UnicodeString,UnicodeText) \
  11. \
  12. RtlInitUnicodeString((UnicodeString),(UnicodeText)); \
  13. \
  14. InitializeObjectAttributes( \
  15. (Obja), \
  16. (UnicodeString), \
  17. OBJ_CASE_INSENSITIVE, \
  18. NULL, \
  19. NULL \
  20. )
  21. BOOLEAN
  22. SetupDelayedFileRename(
  23. VOID
  24. );
  25. //
  26. // Memory routines
  27. //
  28. #define MALLOC(size) RtlAllocateHeap(RtlProcessHeap(),0,(size))
  29. #define FREE(block) RtlFreeHeap(RtlProcessHeap(),0,(block))
  30. #define ARRAYSIZE(a) (sizeof(a) / sizeof((a)[0]))