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.

40 lines
1.0 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992 - 1994.
  5. //
  6. // File: dlltable.h
  7. //
  8. // Contents: DLL tracking class
  9. //
  10. // Classes: CDll
  11. //
  12. // History: 16-Mar-94 DrewB Taken from OLE2 16-bit sources
  13. //
  14. //----------------------------------------------------------------------------
  15. #ifndef __DLLTABLE_H__
  16. #define __DLLTABLE_H__
  17. class FAR CDlls
  18. {
  19. public:
  20. HINSTANCE GetLibrary(LPSTR pLibName, BOOL fAutoFree);
  21. void ReleaseLibrary(HINSTANCE hInst);
  22. void FreeAllLibraries(void);
  23. void FreeUnusedLibraries(void);
  24. CDlls() { m_size = 0; m_pDlls = NULL; }
  25. ~CDlls() {}
  26. private:
  27. UINT m_size; // Number of entries
  28. struct {
  29. HINSTANCE hInst;
  30. ULONG refsTotal; // total number of refs
  31. ULONG refsAuto; // number of autounload refs
  32. LPFNCANUNLOADNOW lpfnDllCanUnloadNow; // set on first load
  33. } FAR* m_pDlls;
  34. };
  35. #endif // #ifndef __DLLTABLE_H__