summaryrefslogtreecommitdiff
path: root/libxvmc/xf86dri.c
diff options
context:
space:
mode:
authorThomas Hellström <thomas@shipmail.org>2005-12-02 20:42:49 +0000
committerThomas Hellström <thomas@shipmail.org>2005-12-02 20:42:49 +0000
commita2e02ab2a34ee23d545fee9e43367e06da08e3d3 (patch)
treeb701ed812809c1f17b093f38bd6c216af0917862 /libxvmc/xf86dri.c
parentd53b2cc412cdb62948b9ebefc69ea144fd8f1b66 (diff)
64 bit fixes on libviaXvMC*
Diffstat (limited to 'libxvmc/xf86dri.c')
-rw-r--r--libxvmc/xf86dri.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/libxvmc/xf86dri.c b/libxvmc/xf86dri.c
index 1a43177..27ba480 100644
--- a/libxvmc/xf86dri.c
+++ b/libxvmc/xf86dri.c
@@ -201,9 +201,10 @@ static XEXT_GENERATE_CLOSE_DISPLAY (close_display, xf86dri_info)
*hSAREA = rep.hSAREALow;
#ifdef LONG64
- *hSAREA |= ((drm_handle_t)rep.hSAREAHigh) << 32;
+ if (sizeof(drm_handle_t) == 8) {
+ *hSAREA |= ((unsigned long)rep.hSAREAHigh) << 32;
+ }
#endif
-
if (rep.length) {
if (!(*busIdString = (char *)Xcalloc(rep.busIdStringLength + 1, 1))) {
_XEatData(dpy, ((rep.busIdStringLength+3) & ~3));
@@ -563,7 +564,9 @@ Bool uniDRIDestroyDrawable( Display * ndpy, int screen,
*hFrameBuffer = rep.hFrameBufferLow;
#ifdef LONG64
- *hFrameBuffer |= ((drm_handle_t)rep.hFrameBufferHigh) << 32;
+ if (sizeof(drm_handle_t) == 8) {
+ *hFrameBuffer |= ((unsigned long)rep.hFrameBufferHigh) << 32;
+ }
#endif
*fbOrigin = rep.framebufferOrigin;