Index: include/ndk/umtypes.h =================================================================== --- include/ndk/umtypes.h (revision 68086) +++ include/ndk/umtypes.h (working copy) @@ -103,15 +103,15 @@ // // Limits // -#define MINCHAR 0x80 -#define MAXCHAR 0x7f -#define MINSHORT 0x8000 -#define MAXSHORT 0x7fff -#define MINLONG 0x80000000 -#define MAXLONG 0x7fffffff -#define MAXUCHAR 0xff -#define MAXUSHORT 0xffff -#define MAXULONG 0xffffffff +#define MINCHAR ((CHAR)0x80) +#define MAXCHAR ((CHAR)0x7f) +#define MINSHORT ((SHORT)0x8000) +#define MAXSHORT ((SHORT)0x7fff) +#define MINLONG ((LONG)0x80000000) +#define MAXLONG ((LONG)0x7fffffff) +#define MAXUCHAR ((UCHAR)0xff) +#define MAXUSHORT ((USHORT)0xffff) +#define MAXULONG ((ULONG)0xffffffff) // // Basic Types that aren't defined in User-Mode Headers Index: include/psdk/ntdef.h =================================================================== --- include/psdk/ntdef.h (revision 68086) +++ include/psdk/ntdef.h (working copy) @@ -817,15 +817,15 @@ #define COMPILETIME_OR_5FLAGS(a,b,c,d,e) ((UINT)(a)|(UINT)(b)|(UINT)(c)|(UINT)(d)|(UINT)(e)) /* Type Limits */ -#define MINCHAR 0x80 -#define MAXCHAR 0x7f -#define MINSHORT 0x8000 -#define MAXSHORT 0x7fff -#define MINLONG 0x80000000 -#define MAXLONG 0x7fffffff -#define MAXUCHAR 0xff -#define MAXUSHORT 0xffff -#define MAXULONG 0xffffffff +#define MINCHAR ((CHAR)0x80) +#define MAXCHAR ((CHAR)0x7f) +#define MINSHORT ((SHORT)0x8000) +#define MAXSHORT ((SHORT)0x7fff) +#define MINLONG ((LONG)0x80000000) +#define MAXLONG ((LONG)0x7fffffff) +#define MAXUCHAR ((UCHAR)0xff) +#define MAXUSHORT ((USHORT)0xffff) +#define MAXULONG ((ULONG)0xffffffff) #define MAXLONGLONG (0x7fffffffffffffffLL) /* 32 to 64 bit multiplication. GCC is really bad at optimizing the native math */ Index: include/psdk/winnt.h =================================================================== --- include/psdk/winnt.h (revision 68086) +++ include/psdk/winnt.h (working copy) @@ -751,15 +751,15 @@ #define COMPILETIME_OR_5FLAGS(a,b,c,d,e) ((UINT)(a)|(UINT)(b)|(UINT)(c)|(UINT)(d)|(UINT)(e)) /* Type Limits */ -#define MINCHAR 0x80 -#define MAXCHAR 0x7f -#define MINSHORT 0x8000 -#define MAXSHORT 0x7fff -#define MINLONG 0x80000000 -#define MAXLONG 0x7fffffff -#define MAXBYTE 0xff -#define MAXWORD 0xffff -#define MAXDWORD 0xffffffff +#define MINCHAR ((CHAR)0x80) +#define MAXCHAR ((CHAR)0x7f) +#define MINSHORT ((SHORT)0x8000) +#define MAXSHORT ((SHORT)0x7fff) +#define MINLONG ((LONG)0x80000000) +#define MAXLONG ((LONG)0x7fffffff) +#define MAXBYTE ((BYTE)0xff) +#define MAXWORD ((WORD)0xffff) +#define MAXDWORD ((DWORD)0xffffffff) #define MAXLONGLONG (0x7fffffffffffffffLL) /* 32 to 64 bit multiplication. GCC is really bad at optimizing the native math */