mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 02:15:43 +00:00
[SHIMLIB] c++ compatibility
This commit is contained in:
parent
cfd1647914
commit
aabefa30d5
2 changed files with 15 additions and 5 deletions
|
@ -1,8 +1,8 @@
|
||||||
/*
|
/*
|
||||||
* PROJECT: ReactOS Shim helper library
|
* PROJECT: ReactOS Shim helper library
|
||||||
* LICENSE: GPL-2.0+ (https://spdx.org/licenses/GPL-2.0+)
|
* LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
|
||||||
* PURPOSE: Shimlib helper file, used to register shims setup with macro's from setup_shim.inl
|
* PURPOSE: Shimlib helper file, used to register shims setup with macro's from setup_shim.inl
|
||||||
* COPYRIGHT: Copyright 2016,2017 Mark Jansen (mark.jansen@reactos.org)
|
* COPYRIGHT: Copyright 2016-2019 Mark Jansen (mark.jansen@reactos.org)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef SHIM_NS
|
#ifndef SHIM_NS
|
||||||
|
@ -37,7 +37,7 @@ PHOOKAPI WINAPI SHIM_OBJ_NAME(GetHookAPIs)(DWORD fdwReason, PCSTR pszCmdLine, PD
|
||||||
{
|
{
|
||||||
SHIM_OBJ_NAME(g_szCommandLine) = "";
|
SHIM_OBJ_NAME(g_szCommandLine) = "";
|
||||||
}
|
}
|
||||||
SHIM_OBJ_NAME(g_pAPIHooks) = ShimLib_ShimMalloc(sizeof(HOOKAPI) * SHIM_NUM_HOOKS);
|
SHIM_OBJ_NAME(g_pAPIHooks) = (PHOOKAPI)ShimLib_ShimMalloc(sizeof(HOOKAPI) * SHIM_NUM_HOOKS);
|
||||||
if (SHIM_NUM_HOOKS)
|
if (SHIM_NUM_HOOKS)
|
||||||
ZeroMemory(SHIM_OBJ_NAME(g_pAPIHooks), sizeof(HOOKAPI) * SHIM_NUM_HOOKS);
|
ZeroMemory(SHIM_OBJ_NAME(g_pAPIHooks), sizeof(HOOKAPI) * SHIM_NUM_HOOKS);
|
||||||
*pdwHookCount = SHIM_NUM_HOOKS;
|
*pdwHookCount = SHIM_NUM_HOOKS;
|
||||||
|
|
|
@ -1,12 +1,18 @@
|
||||||
/*
|
/*
|
||||||
* PROJECT: ReactOS Shim helper library
|
* PROJECT: ReactOS Shim helper library
|
||||||
* LICENSE: GPL-2.0+ (https://spdx.org/licenses/GPL-2.0+)
|
* LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
|
||||||
* PURPOSE: ReactOS Shim Engine common functions / structures
|
* PURPOSE: ReactOS Shim Engine common functions / structures
|
||||||
* COPYRIGHT: Copyright 2016-2018 Mark Jansen (mark.jansen@reactos.org)
|
* COPYRIGHT: Copyright 2016-2019 Mark Jansen (mark.jansen@reactos.org)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
typedef struct tagHOOKAPI
|
typedef struct tagHOOKAPI
|
||||||
{
|
{
|
||||||
PCSTR LibraryName;
|
PCSTR LibraryName;
|
||||||
|
@ -91,3 +97,7 @@ typedef struct tagSHIMREG
|
||||||
#error Your compiler is not supported.
|
#error Your compiler is not supported.
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
} // extern "C"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue