From 6f037d78fb8ca9badfe780f0ebb37a271a8644c5 Mon Sep 17 00:00:00 2001 From: Matthieu Herrb Date: Sat, 10 Mar 2012 23:31:34 +0000 Subject: Fix build on 32 bit architectures. Problem noticed by naddy@. --- lib/libXxf86dga/src/XF86DGA2.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/libXxf86dga') diff --git a/lib/libXxf86dga/src/XF86DGA2.c b/lib/libXxf86dga/src/XF86DGA2.c index e81b4866c..39ad1ccfe 100644 --- a/lib/libXxf86dga/src/XF86DGA2.c +++ b/lib/libXxf86dga/src/XF86DGA2.c @@ -20,6 +20,7 @@ Copyright (c) 1995,1996 The XFree86 Project, Inc #include #include #include +#include /* If you change this, change the Bases[] array below as well */ @@ -928,7 +929,7 @@ DGAMapPhysical( if ((pMap->fd = open(name, O_RDWR)) < 0) return False; pMap->virtual = mmap(NULL, size, PROT_READ | PROT_WRITE, - MAP_FILE | MAP_SHARED, pMap->fd, (off_t)base); + MAP_FILE | MAP_SHARED, pMap->fd, (off_t)(uintptr_t)base); if (pMap->virtual == (void *)-1) return False; mprotect(pMap->virtual, size, PROT_READ | PROT_WRITE); -- cgit v1.2.3