Skip to content

Commit b414e1e

Browse files
committed
[NTOS] Don't define _IN_KERNEL_ globally for the kernel, but just where it's needed: when including regstr.h.
1 parent 551d28e commit b414e1e

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

ntoskrnl/include/ntoskrnl.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,13 @@
5858
#include <ndk/rtlfuncs.h>
5959
#include <ndk/sefuncs.h>
6060
#include <ndk/vftypes.h>
61+
6162
#undef TEXT
6263
#define TEXT(s) L##s
64+
65+
#define _IN_KERNEL_
6366
#include <regstr.h>
67+
6468
#include <ntstrsafe.h>
6569
#include <ntpoapi.h>
6670
#define ENABLE_INTSAFE_SIGNED_FUNCTIONS

ntoskrnl/ntos.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ include_directories(
1111
add_definitions(
1212
-D_NTOSKRNL_
1313
-D_NTSYSTEM_
14-
-D_IN_KERNEL_
1514
-DNTDDI_VERSION=0x05020400)
1615

1716
if(NOT DEFINED NEWCC)

0 commit comments

Comments
 (0)