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.

50 lines
1.9 KiB

  1. /*++
  2. Copyright (c) 2001 Microsoft Corporation
  3. Abstract:
  4. Environment independed definition of system functions,
  5. that should be implemented for specific enviroment.
  6. Author:
  7. Souren Aghajanyan (sourenag) 24-Sep-2001
  8. Revision History:
  9. <alias> <date> <comments>
  10. --*/
  11. #pragma once
  12. typedef HANDLE (*MY_OPENMUTEX)(PCWSTR pObjectName);
  13. typedef HANDLE (*MY_CREATEMUTEX)(PCWSTR pObjectName, BOOL bInitialOwnership);
  14. typedef VOID (*MY_RELEASEMUTEX)(HANDLE hObject);
  15. typedef DWORD (*MY_WAITFORSINGLEOBJECT)(HANDLE hObject, DWORD dwTimeout);
  16. typedef VOID (*MY_CLOSEHANDLE)(HANDLE hObject);
  17. typedef HANDLE (*MY_OPENSHAREDMEMORY)(PCWSTR pObjectName);
  18. typedef HANDLE (*MY_CREATESHAREDMEMORY)(UINT uiInitialSizeOfMapView, PCWSTR pObjectName);
  19. typedef PVOID (*MY_MAPSHAREDMEMORY)(HANDLE hObject);
  20. typedef BOOL (*MY_UNMAPSHAREDMEMORY)(PVOID pSharedMemory);
  21. typedef HANDLE (*MY_CREATESHAREDFILE)(PCWSTR pFilePath, DWORD dwShareMode, DWORD dwCreationDisposition, DWORD dwFlagsAndAttributes);
  22. typedef BOOL (*MY_SETFILEPOINTER)(HANDLE hObject, UINT uiOffset, DWORD dwMoveMethod);
  23. typedef BOOL (*MY_WRITEFILE)(HANDLE hObject, PVOID pBuffer, UINT uiNumberOfBytesToWrite, DWORD * pdwNumberOfBytesWritten);
  24. typedef UINT (*MY_GETPROCESSORNUMBER)();
  25. extern MY_OPENMUTEX g_OpenMutex;
  26. extern MY_CREATEMUTEX g_CreateMutex;
  27. extern MY_RELEASEMUTEX g_ReleaseMutex;
  28. extern MY_WAITFORSINGLEOBJECT g_WaitForSingleObject;
  29. extern MY_CLOSEHANDLE g_CloseHandle;
  30. extern MY_OPENSHAREDMEMORY g_OpenSharedMemory;
  31. extern MY_CREATESHAREDMEMORY g_CreateSharedMemory;
  32. extern MY_MAPSHAREDMEMORY g_MapSharedMemory;
  33. extern MY_UNMAPSHAREDMEMORY g_UnMapSharedMemory;
  34. extern MY_CREATESHAREDFILE g_CreateSharedFile;
  35. extern MY_SETFILEPOINTER g_SetFilePointer;
  36. extern MY_WRITEFILE g_WriteFile;
  37. extern MY_GETPROCESSORNUMBER g_GetProcessorsNumber;
  38. BOOL InitSystemFunctions();