https://git.reactos.org/?p=reactos.git;a=commitdiff;h=b414e1e4d7c89803fd371…
commit b414e1e4d7c89803fd3712c721039266338a35dc
Author: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
AuthorDate: Tue Mar 8 05:35:43 2022 +0100
Commit: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
CommitDate: Sat May 7 18:38:35 2022 +0200
[NTOS] Don't define _IN_KERNEL_ globally for the kernel, but just where it's
needed: when including regstr.h.
---
ntoskrnl/include/ntoskrnl.h | 4 ++++
ntoskrnl/ntos.cmake | 1 -
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/ntoskrnl/include/ntoskrnl.h b/ntoskrnl/include/ntoskrnl.h
index 643562e60f0..6f2f5379bec 100644
--- a/ntoskrnl/include/ntoskrnl.h
+++ b/ntoskrnl/include/ntoskrnl.h
@@ -58,9 +58,13 @@
#include <ndk/rtlfuncs.h>
#include <ndk/sefuncs.h>
#include <ndk/vftypes.h>
+
#undef TEXT
#define TEXT(s) L##s
+
+#define _IN_KERNEL_
#include <regstr.h>
+
#include <ntstrsafe.h>
#include <ntpoapi.h>
#define ENABLE_INTSAFE_SIGNED_FUNCTIONS
diff --git a/ntoskrnl/ntos.cmake b/ntoskrnl/ntos.cmake
index eb6cfa817c3..2284563e436 100644
--- a/ntoskrnl/ntos.cmake
+++ b/ntoskrnl/ntos.cmake
@@ -11,7 +11,6 @@ include_directories(
add_definitions(
-D_NTOSKRNL_
-D_NTSYSTEM_
- -D_IN_KERNEL_
-DNTDDI_VERSION=0x05020400)
if(NOT DEFINED NEWCC)