ReactOS  0.4.13-dev-479-gec9c8fd
main.c
Go to the documentation of this file.
1 /*
2  * PROJECT: ReactOS 'General' Shim library
3  * LICENSE: GPL-2.0+ (https://spdx.org/licenses/GPL-2.0+)
4  * PURPOSE: Shim entrypoint
5  * COPYRIGHT: Copyright 2016,2017 Mark Jansen (mark.jansen@reactos.org)
6  */
7 
8 #define WIN32_NO_STATUS
9 #include <windef.h>
10 #include <winbase.h>
11 #include <strsafe.h>
12 #include <shimlib.h>
13 
14 /* Forward to the generic implementation */
15 PHOOKAPI WINAPI GetHookAPIs(IN LPCSTR szCommandLine, IN LPCWSTR wszShimName, OUT PDWORD pdwHookCount)
16 {
17  return ShimLib_GetHookAPIs(szCommandLine, wszShimName, pdwHookCount);
18 }
19 
20 /* Forward to the generic implementation */
22 {
23  return ShimLib_NotifyShims(fdwReason, ptr);
24 }
25 
27 {
28  switch(dwReason)
29  {
30  case DLL_PROCESS_ATTACH:
32  break;
33  case DLL_PROCESS_DETACH:
35  break;
36  }
37  return TRUE;
38 }
#define IN
Definition: typedefs.h:38
#define TRUE
Definition: types.h:120
const WCHAR * LPCWSTR
Definition: xmlstorage.h:185
BOOL WINAPI NotifyShims(DWORD fdwReason, PVOID ptr)
Definition: main.c:21
#define DLL_PROCESS_ATTACH
Definition: compat.h:120
PHOOKAPI WINAPI ShimLib_GetHookAPIs(IN LPCSTR szCommandLine, IN LPCWSTR wszShimName, OUT PDWORD pdwHookCount)
Definition: shimlib.c:111
PHOOKAPI WINAPI GetHookAPIs(IN LPCSTR szCommandLine, IN LPCWSTR wszShimName, OUT PDWORD pdwHookCount)
Definition: main.c:15
void ShimLib_Init(HINSTANCE hInstance)
Definition: shimlib.c:30
DWORD dwReason
Definition: misc.cpp:154
void ShimLib_Deinit(VOID)
Definition: shimlib.c:39
unsigned int BOOL
Definition: ntddk_ex.h:94
static PVOID ptr
Definition: dispmode.c:27
const char * LPCSTR
Definition: xmlstorage.h:183
#define DLL_PROCESS_DETACH
Definition: compat.h:119
#define WINAPI
Definition: msvc.h:8
unsigned long DWORD
Definition: ntddk_ex.h:95
HINSTANCE hInstance
Definition: main.c:36
DWORD * PDWORD
Definition: pedump.c:68
#define OUT
Definition: typedefs.h:39
BOOL WINAPI ShimLib_NotifyShims(DWORD fdwReason, PVOID ptr)
Definition: shimlib.c:136
BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)
Definition: main.c:26