From d5daba478954072e23031c47aaa32682dd63f9ea Mon Sep 17 00:00:00 2001 From: Timo Kreuzer Date: Wed, 3 Jun 2026 13:27:24 +0300 Subject: [PATCH] [NDK] Add missing extern "C" --- sdk/include/ndk/iotypes.h | 8 ++++++++ sdk/include/ndk/kdfuncs.h | 9 +++++++++ sdk/include/ndk/lpctypes.h | 8 ++++++++ sdk/include/ndk/mmfuncs.h | 8 ++++++++ 4 files changed, 33 insertions(+) diff --git a/sdk/include/ndk/iotypes.h b/sdk/include/ndk/iotypes.h index 5610099f884..37707afce9a 100644 --- a/sdk/include/ndk/iotypes.h +++ b/sdk/include/ndk/iotypes.h @@ -25,6 +25,10 @@ Author: #include #include +#ifdef __cplusplus +extern "C" { +#endif + // // I/O Completion Access Rights // @@ -1274,4 +1278,8 @@ typedef struct _REPARSE_DATA_BUFFER { #endif // NTOS_MODE_USER +#ifdef __cplusplus +} +#endif + #endif diff --git a/sdk/include/ndk/kdfuncs.h b/sdk/include/ndk/kdfuncs.h index 0ab68c26bcd..1f2278d477d 100644 --- a/sdk/include/ndk/kdfuncs.h +++ b/sdk/include/ndk/kdfuncs.h @@ -25,6 +25,10 @@ Author: #include #include +#ifdef __cplusplus +extern "C" { +#endif + #ifndef NTOS_MODE_USER // @@ -110,4 +114,9 @@ ZwSystemDebugControl( _In_ ULONG OutputBufferLength, _Out_opt_ PULONG ReturnLength ); + +#ifdef __cplusplus +} // extern "C" #endif + +#endif // _KDFUNCS_H diff --git a/sdk/include/ndk/lpctypes.h b/sdk/include/ndk/lpctypes.h index 23d2f48005f..a8e67a59bdd 100644 --- a/sdk/include/ndk/lpctypes.h +++ b/sdk/include/ndk/lpctypes.h @@ -25,6 +25,10 @@ Author: #include //#include +#ifdef __cplusplus +extern "C" { +#endif + #ifndef NTOS_MODE_USER // @@ -293,4 +297,8 @@ typedef struct _CLIENT_DIED_MSG sizeof(PORT_MESSAGE) - \ sizeof(LPCP_CONNECTION_MESSAGE)) +#ifdef __cplusplus +} +#endif + #endif // _LPCTYPES_H diff --git a/sdk/include/ndk/mmfuncs.h b/sdk/include/ndk/mmfuncs.h index cd4f733f15e..9ab3fdde6cf 100644 --- a/sdk/include/ndk/mmfuncs.h +++ b/sdk/include/ndk/mmfuncs.h @@ -25,6 +25,10 @@ Author: #include #include +#ifdef __cplusplus +extern "C" { +#endif + #ifndef NTOS_MODE_USER // @@ -495,4 +499,8 @@ ZwWriteVirtualMemory( _Out_opt_ PSIZE_T NumberOfBytesWritten ); +#ifdef __cplusplus +} // extern "C" #endif + +#endif // _MMFUNCS_H