summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/ffb/ffb_xmesa.c
diff options
context:
space:
mode:
authorAlan Hourihane <alanh@tungstengraphics.com>2005-08-15 06:59:24 +0000
committerAlan Hourihane <alanh@tungstengraphics.com>2005-08-15 06:59:24 +0000
commitdabec11d277e68b6940e741651e61102767240b9 (patch)
tree12e8d6988b4b20a0d4fbcf4312ee89f66ddb1225 /src/mesa/drivers/dri/ffb/ffb_xmesa.c
parent69dc32cfac945bf664ddfbd6f0116404f893e66e (diff)
Add Egberts fixes for 64bit architectures
Add additional checks for the *DRIRec info structure passed in from the device driver. This ensures that things fallback to indirect rendering if the DDX driver has had modifications (i.e. removal of the drmAddress field).
Diffstat (limited to 'src/mesa/drivers/dri/ffb/ffb_xmesa.c')
-rw-r--r--src/mesa/drivers/dri/ffb/ffb_xmesa.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/ffb/ffb_xmesa.c b/src/mesa/drivers/dri/ffb/ffb_xmesa.c
index e260e1de24b..5b50d24d9e3 100644
--- a/src/mesa/drivers/dri/ffb/ffb_xmesa.c
+++ b/src/mesa/drivers/dri/ffb/ffb_xmesa.c
@@ -68,6 +68,12 @@ ffbInitDriver(__DRIscreenPrivate *sPriv)
if (getenv("LIBGL_FORCE_XSERVER"))
return GL_FALSE;
+
+ if (sPriv->devPrivSize != sizeof(FFBDRIRec)) {
+ fprintf(stderr,"\nERROR! sizeof(FFBDRIRec) does not match passed size from device driver\n");
+ return GL_FALSE;
+ }
+
/* Allocate the private area. */
ffbScreen = (ffbScreenPrivate *) MALLOC(sizeof(ffbScreenPrivate));
if (!ffbScreen)
@@ -721,7 +727,7 @@ void * __driCreateNewScreen_20050727( __DRInativeDisplay *dpy, int scrn, __DRIsc
{
__DRIscreenPrivate *psp;
- static const __DRIversion ddx_expected = { 0, 0, 1 };
+ static const __DRIversion ddx_expected = { 0, 1, 1 };
static const __DRIversion dri_expected = { 4, 0, 0 };
static const __DRIversion drm_expected = { 0, 0, 1 };