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.

69 lines
2.2 KiB

  1. #ifndef __EMPTY_VOLUME_CACHE__
  2. #define __EMPTY_VOLUME_CACHE__
  3. #include "utils.h"
  4. // Define node storing a path read from the registry in a singly-linked list.
  5. typedef struct _TAG_CACHE_PATH_NODE CACHE_PATH_NODE;
  6. typedef CACHE_PATH_NODE* LPCACHE_PATH_NODE;
  7. struct _TAG_CACHE_PATH_NODE
  8. {
  9. TCHAR szCachePath[MAX_PATH];
  10. LPCACHE_PATH_NODE pNext;
  11. };
  12. // Define node storing control handles in a singly-linked list.
  13. typedef struct _TAG_CONTROL_HANDLE_NODE CONTROL_HANDLE_NODE;
  14. typedef CONTROL_HANDLE_NODE* LPCONTROL_HANDLE_NODE;
  15. struct _TAG_CONTROL_HANDLE_NODE
  16. {
  17. HANDLE hControl;
  18. LPCONTROL_HANDLE_NODE pNext;
  19. };
  20. // Define node storing heads and tails of control handle lists in a
  21. // singly-linked list.
  22. // There is a control handle list for each volume.
  23. typedef struct _TAG_CONTROL_HANDLE_HEADER CONTROL_HANDLE_HEADER;
  24. typedef CONTROL_HANDLE_HEADER* LPCONTROL_HANDLE_HEADER;
  25. struct _TAG_CONTROL_HANDLE_HEADER
  26. {
  27. DWORD dwSpaceUsed;
  28. int nDriveNum;
  29. LPCONTROL_HANDLE_NODE pHandlesHead;
  30. LPCONTROL_HANDLE_NODE pHandlesTail;
  31. LPCONTROL_HANDLE_HEADER pNext;
  32. };
  33. // Handles to activeX controls are cached in memory during calls to
  34. // GetSpaceUsed so that re-enumeration is not needed for subsequent
  35. // calls to Purge.
  36. //
  37. // The structure for storing control handles for various volumes is:
  38. //
  39. // m_pControlsTail -+
  40. // |
  41. // \|/
  42. // m_pControlsHead --> Header01 --> Header02 --> Header03 --> NULL
  43. // | | |
  44. // +- C: +- D: +- E:
  45. // | | |
  46. // +- Head01 +- Head02 +- Head03
  47. // | | |
  48. // +- Tail01 +- Tail02 +- Tail03
  49. //
  50. // where
  51. // HeaderXX is of type CONTROL_HANDLE_HEADER, and
  52. // HeadXX and TailXX are of type LPCONTROL_HANDLE_NODE.
  53. //
  54. // HeadXX and TailXX are respectively head and tail pointers to a list
  55. // of handles. Those are handles to controls installed on the drive
  56. // specified in HeaderXX.
  57. //
  58. #endif // __EMPTY_VOLUME_CACHE__