From: Eric Pouech <epouech@codeweavers.com> Mainly wrapping the header inside extern "C" {...} Adding re-inclusion guard for memoryapi.h Part 4: [m] range. Signed-off-by: Eric Pouech <epouech@codeweavers.com> --- include/memoryapi.h | 13 +++++++++++++ include/mgmtapi.h | 8 ++++++++ include/mmreg.h | 9 +++++++++ include/msacmdrv.h | 8 ++++++++ include/mstcpip.h | 8 ++++++++ 5 files changed, 46 insertions(+) diff --git a/include/memoryapi.h b/include/memoryapi.h index 2cfcdd5a273..ac3274b9688 100644 --- a/include/memoryapi.h +++ b/include/memoryapi.h @@ -14,6 +14,13 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ +#ifndef _MEMORYAPI_H_ +#define _MEMORYAPI_H_ + +#ifdef __cplusplus +extern "C" { +#endif + typedef enum WIN32_MEMORY_INFORMATION_CLASS { MemoryRegionInfo @@ -44,3 +51,9 @@ typedef struct WIN32_MEMORY_REGION_INFORMATION WINBASEAPI HANDLE WINAPI CreateFileMapping2(HANDLE,LPSECURITY_ATTRIBUTES,ULONG,ULONG,ULONG,ULONG64,const WCHAR*,MEM_EXTENDED_PARAMETER*,ULONG); WINBASEAPI DWORD WINAPI DiscardVirtualMemory(void *addr, SIZE_T size); WINBASEAPI BOOL WINAPI QueryVirtualMemoryInformation(HANDLE process,const void *addr, WIN32_MEMORY_INFORMATION_CLASS info_class, void *info, SIZE_T size, SIZE_T *ret_size); + +#ifdef __cplusplus +} +#endif + +#endif /* _MEMORYAPI_H_ */ diff --git a/include/mgmtapi.h b/include/mgmtapi.h index 0d22a7aceac..b44c7ebd595 100644 --- a/include/mgmtapi.h +++ b/include/mgmtapi.h @@ -19,6 +19,14 @@ #ifndef _INC_MGMTAPI #define _INC_MGMTAPI +#ifdef __cplusplus +extern "C" { +#endif + typedef void *LPSNMP_MGR_SESSION; +#ifdef __cplusplus +} +#endif + #endif /* _INC_MGMTAPI */ diff --git a/include/mmreg.h b/include/mmreg.h index 061aaa572a3..feefe9c34a6 100644 --- a/include/mmreg.h +++ b/include/mmreg.h @@ -25,6 +25,11 @@ #pragma pack(push,1) +#ifdef __cplusplus +extern "C" { +#endif + + /*********************************************************************** * Defines/Enums */ @@ -819,6 +824,10 @@ typedef struct tagEXBMINFOHEADER { #endif +#ifdef __cplusplus +} +#endif + #pragma pack(pop) #endif /* __WINE_MMREG_H */ diff --git a/include/msacmdrv.h b/include/msacmdrv.h index 3c17f9866de..f31258ba294 100644 --- a/include/msacmdrv.h +++ b/include/msacmdrv.h @@ -21,6 +21,10 @@ #ifndef __WINE_MSACMDRV_H #define __WINE_MSACMDRV_H +#ifdef __cplusplus +extern "C" { +#endif + #include <stdarg.h> #include <windef.h> @@ -157,4 +161,8 @@ typedef struct _ACMDRVFORMATSUGGEST DWORD cbwfxDst; } ACMDRVFORMATSUGGEST, *PACMDRVFORMATSUGGEST; +#ifdef __cplusplus +} +#endif + #endif /* __WINE_MSACMDRV_H */ diff --git a/include/mstcpip.h b/include/mstcpip.h index c7dffd55f12..95d3da0f1d9 100644 --- a/include/mstcpip.h +++ b/include/mstcpip.h @@ -18,6 +18,10 @@ #ifndef __WINE_MSTCPIP_H #define __WINE_MSTCPIP_H +#ifdef __cplusplus +extern "C" { +#endif + #include <nldef.h> struct tcp_keepalive @@ -85,4 +89,8 @@ struct tcp_keepalive #endif /* USE_WS_PREFIX */ +#ifdef __cplusplus +} +#endif + #endif /* __WINE_MSTCPIP_H */ -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/10303