Skip to content

Commit e7b7d31

Browse files
authored
Fix some compilation errors in ARM64 (winsiderss#565)
1 parent 2e35277 commit e7b7d31

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

KProcessHacker/include/ntfill.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ KeInsertQueueApc(
141141

142142
FORCEINLINE PVOID ObpDecodeObject(PVOID Object)
143143
{
144-
#ifdef _M_X64
144+
#if (defined _M_X64) || (defined _M_ARM64)
145145
if (KphDynNtVersion >= PHNT_WIN8)
146146
{
147147
if (KphDynObDecodeShift != ULONG_MAX)
@@ -160,7 +160,7 @@ FORCEINLINE PVOID ObpDecodeObject(PVOID Object)
160160

161161
FORCEINLINE ULONG ObpGetHandleAttributes(PHANDLE_TABLE_ENTRY HandleTableEntry)
162162
{
163-
#ifdef _M_X64
163+
#if (defined _M_X64) || (defined _M_ARM64)
164164
if (KphDynNtVersion >= PHNT_WIN8)
165165
{
166166
if (KphDynObAttributesShift != ULONG_MAX)
@@ -227,7 +227,7 @@ typedef struct _OBJECT_HEADER
227227
QUAD Body;
228228
} OBJECT_HEADER, *POBJECT_HEADER;
229229

230-
#ifdef _M_X64
230+
#if (defined _M_X64) || (defined _M_ARM64)
231231
C_ASSERT(FIELD_OFFSET(OBJECT_HEADER, Body) == 0x030);
232232
C_ASSERT(sizeof(OBJECT_HEADER) == 0x038);
233233
#else

KProcessHacker/object.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ VOID KphUnlockHandleTableEntry(
125125

126126
// Set the unlocked bit.
127127

128-
#ifdef _M_X64
128+
#if (defined _M_X64) || (defined _M_ARM64)
129129
InterlockedExchangeAdd64(&HandleTableEntry->Value, 1);
130130
#else
131131
InterlockedExchangeAdd(&HandleTableEntry->Value, 1);

ProcessHacker/notifico.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636

3737
#include <mainwndp.h>
3838
#include <notificop.h>
39+
#include <malloc.h>
3940

4041
BOOLEAN PhNfMiniInfoEnabled = FALSE;
4142
BOOLEAN PhNfMiniInfoPinned = FALSE;

tools/peview/pdb.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
#include <symprv.h>
2626
#include <pdb.h>
2727
#include <uxtheme.h>
28+
#include <malloc.h>
2829

2930
typedef BOOL (WINAPI *_SymInitializeW)(
3031
_In_ HANDLE hProcess,

0 commit comments

Comments
 (0)