summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Huddleston <jeremyhu@apple.com>2012-03-08 11:49:36 -0800
committerJeremy Huddleston <jeremyhu@apple.com>2012-03-08 11:49:36 -0800
commit56b5a5887349e9d0e1d28da157fe6441ca691f56 (patch)
tree73c4603f3eb25824513cb1f0d25f06ad984d5a83
parent3dad5d7c34c5787f0466b9ff50d7c26cd18e37bd (diff)
Build fix when sizeof(off_t) > sizeof(void *)
https://trac.macports.org/ticket/33532 Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
-rw-r--r--src/XF86DGA2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/XF86DGA2.c b/src/XF86DGA2.c
index e81b486..32f455b 100644
--- a/src/XF86DGA2.c
+++ b/src/XF86DGA2.c
@@ -928,7 +928,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);