diff -r 326e468615ed -r 153e2d943cc3 core/sourcehook/sh_memory.h --- a/core/sourcehook/sh_memory.h Tue Dec 23 00:08:01 2008 -0500 +++ b/core/sourcehook/sh_memory.h Mon Feb 16 15:52:46 2009 -0500 @@ -26,6 +26,7 @@ # include # include # include +# include // http://www.die.net/doc/linux/man/man2/mprotect.2.html # include # ifndef PAGESIZE @@ -37,8 +38,8 @@ // We need to align addr down to pagesize on linux // We assume PAGESIZE is a power of two -# define SH_LALIGN(x) (void*)((intptr_t)(x) & ~(PAGESIZE-1)) -# define SH_LALDIF(x) ((intptr_t)(x) % PAGESIZE) +# define SH_LALIGN(x) (void*)((uintptr_t)(x) & ~(PAGESIZE-1)) +# define SH_LALDIF(x) ((uintptr_t)(x) % PAGESIZE) # else # error Unsupported OS/Compiler # endif