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.

31 lines
700 B

  1. // File: pfnver.cpp
  2. #include "precomp.h"
  3. #include "pfnver.h"
  4. #ifdef DEBUG
  5. HINSTANCE DLLVER::m_hInstance = NULL;
  6. PFN_GETVERINFOSIZE DLLVER::GetFileVersionInfoSize = NULL;
  7. PFN_GETVERINFO DLLVER::GetFileVersionInfo = NULL;
  8. PFN_VERQUERYVAL DLLVER::VerQueryValue = NULL;
  9. #define DLLVER_APIFCN_ENTRY(pfn) {(PVOID *) &DLLVER::##pfn, #pfn}
  10. APIFCN s_apiFcnDllVer[] = {
  11. DLLVER_APIFCN_ENTRY(GetFileVersionInfoSize),
  12. DLLVER_APIFCN_ENTRY(GetFileVersionInfo),
  13. DLLVER_APIFCN_ENTRY(VerQueryValue),
  14. };
  15. HRESULT DLLVER::Init(void)
  16. {
  17. if (NULL != m_hInstance)
  18. return S_OK;
  19. return HrInitLpfn(s_apiFcnDllVer, ARRAY_ELEMENTS(s_apiFcnDllVer), &m_hInstance, TEXT("VERSION.dll"));
  20. }
  21. #endif /* DEBUG */