From 6258b76c49f49a56a7c713914b798e80c6553b06 Mon Sep 17 00:00:00 2001 From: Karl Schultz Date: Thu, 5 May 2005 21:08:07 +0000 Subject: Port Mesa to build on a P64 platform (e.g., Win64). P64 platforms use 64-bit pointers and 32-bit longs. So, operations like casting pointers to unsigned long and back to pointer won't work. glheader.h now includes files to define uintptr_t, which should instead be used for this sort of operation. It is an integer type that is the same size as a pointer. --- src/mesa/math/m_translate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa/math') diff --git a/src/mesa/math/m_translate.c b/src/mesa/math/m_translate.c index 14beabb978..1bce0f3a0c 100644 --- a/src/mesa/math/m_translate.c +++ b/src/mesa/math/m_translate.c @@ -530,7 +530,7 @@ static void trans_4_GLubyte_4ub_raw(GLubyte (*t)[4], const GLubyte *f = (GLubyte *) Ptr + SRC_START * stride; GLuint i; - if (((((long) f | (long) stride)) & 3L) == 0L) { + if (((((uintptr_t) f | (uintptr_t) stride)) & 3L) == 0L) { /* Aligned. */ for (i = DST_START ; i < n ; i++, f += stride) { -- cgit v1.2.3