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.

66 lines
1.5 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992 - 1997.
  5. //
  6. // File: sht.hxx
  7. //
  8. // Contents:
  9. //
  10. // Classes:
  11. //
  12. // Functions:
  13. //
  14. // History: 2-05-97 RichardW Created
  15. //
  16. //----------------------------------------------------------------------------
  17. #ifndef __SHT_HXX__
  18. #define __SHT_HXX__
  19. typedef struct _SMALL_HANDLE_TABLE {
  20. ULONG Tag ;
  21. ULONG Flags ;
  22. ULONG Count ;
  23. PSEC_HANDLE_ENTRY PendingHandle ;
  24. LIST_ENTRY List ;
  25. PHP_ENUM_CALLBACK_FN DeleteCallback ;
  26. CRITICAL_SECTION Lock ;
  27. } SMALL_HANDLE_TABLE, * PSMALL_HANDLE_TABLE ;
  28. #define SHT_TAG 'XTHS'
  29. #define SHT_NO_SERIALIZE HANDLE_PACKAGE_NO_SERIALIZE
  30. #define SHT_DELETE_CALLBACK HANDLE_PACKAGE_CALLBACK_ON_DELETE
  31. #define SHT_REQUIRE_UNIQUE HANDLE_PACKAGE_REQUIRE_UNIQUE
  32. #define SHT_FLAG_BASE (HANDLE_PACKAGE_MAX_FLAG << 1)
  33. #define SHT_NO_FREE (SHT_FLAG_BASE)
  34. #define SHT_DELETE_PENDING (SHT_FLAG_BASE << 1)
  35. #define SHT_MAX_FLAG (SHT_DELETE_PENDING)
  36. PSEC_HANDLE_ENTRY
  37. ShtpFindHandle(
  38. PSMALL_HANDLE_TABLE Table,
  39. PSecHandle Handle,
  40. ULONG Action,
  41. PBOOL Removed OPTIONAL
  42. );
  43. PSEC_HANDLE_ENTRY
  44. ShtpPopHandle(
  45. PSMALL_HANDLE_TABLE Table
  46. );
  47. VOID
  48. ShtpInsertHandle(
  49. PSMALL_HANDLE_TABLE Table,
  50. PSEC_HANDLE_ENTRY Entry
  51. );
  52. BOOL
  53. ShtDelete(
  54. PVOID HandleTable,
  55. PHP_ENUM_CALLBACK_FN Callback
  56. );
  57. #endif