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.

71 lines
1.2 KiB

  1. typedef struct _nwc_context {
  2. LIST_ENTRY List ;
  3. ULONG RefCount ;
  4. DWORD Flags ;
  5. LPWSTR pszBinderyName;
  6. CCredentials *pCredentials;
  7. NWCONN_HANDLE hConn;
  8. BOOL fLoggedIn;
  9. } NWC_CONTEXT, *PNWC_CONTEXT;
  10. //typedef HANDLE NWC_CONTEXT_HANDLE, *PNWC_CONTEXT_HANDLE;
  11. #define ENTER_BIND_CRITSECT() EnterCriticalSection(&BindCacheCritSect)
  12. #define LEAVE_BIND_CRITSECT() LeaveCriticalSection(&BindCacheCritSect)
  13. #define NWC_CACHE_INVALID (0x00000001)
  14. HRESULT
  15. BindCacheAllocEntry(
  16. NWC_CONTEXT **ppCacheEntry
  17. ) ;
  18. HRESULT
  19. BindCacheFreeEntry(
  20. NWC_CONTEXT *pCacheEntry
  21. ) ;
  22. VOID
  23. BindCacheInvalidateEntry(
  24. NWC_CONTEXT *pCacheEntry
  25. ) ;
  26. PNWC_CONTEXT
  27. BindCacheLookupByConn(
  28. NWCONN_HANDLE hConn
  29. );
  30. PNWC_CONTEXT
  31. BindCacheLookup(
  32. LPWSTR pszBinderyName,
  33. CCredentials& Credentials
  34. ) ;
  35. PNWC_CONTEXT
  36. BindCacheLookupByConn(
  37. NWCONN_HANDLE hConn
  38. ) ;
  39. HRESULT
  40. BindCacheAdd(
  41. LPWSTR pszBinderyName,
  42. CCredentials& Credentials,
  43. BOOL fLoggedIn,
  44. NWC_CONTEXT *pCacheEntry
  45. ) ;
  46. DWORD
  47. BindCacheDeref(
  48. NWC_CONTEXT *pCacheEntry
  49. ) ;
  50. VOID
  51. BindCacheInit(
  52. VOID
  53. );
  54. VOID
  55. BindCacheCleanup(
  56. VOID
  57. );