blob: d8aa139ac715afc904b1ecb4fdcb3a4d6ff10b0e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
The current definitions wrongly assume the only 64-bit architecture is
x86-64. Use the __ILP64__, __LP64__ and __LLP64__ to correctly define
the size of a long and of pointer.
Ideally long, intptr_t and uintptr_t should be used directly but there
might be a (portability ?) reason why it is not the case.
--- a/winpr/include/winpr/wtypes.h
+++ b/winpr/include/winpr/wtypes.h
@@ -37,7 +37,7 @@
#define __int32 int
#define __int64 long long
-#if __x86_64__
+#if __ILP64__ || __LP64__
#define __int3264 __int64
#else
#define __int3264 __int32
@@ -136,7 +136,7 @@ typedef void *PVOID64, *LPVOID64;
typedef const void *LPCVOID;
typedef unsigned short WORD, *PWORD, *LPWORD;
-#if __x86_64__
+#if __ILP64__ || __LP64__ || __LLP64__
typedef __int64 INT_PTR;
typedef unsigned __int64 UINT_PTR;
#else
|