diff options
author | Alan Hourihane <alanh@tungstengraphics.com> | 2005-08-15 06:59:24 +0000 |
---|---|---|
committer | Alan Hourihane <alanh@tungstengraphics.com> | 2005-08-15 06:59:24 +0000 |
commit | dabec11d277e68b6940e741651e61102767240b9 (patch) | |
tree | 12e8d6988b4b20a0d4fbcf4312ee89f66ddb1225 /src/mesa/drivers/dri/s3v | |
parent | 69dc32cfac945bf664ddfbd6f0116404f893e66e (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/s3v')
-rw-r--r-- | src/mesa/drivers/dri/s3v/s3v_screen.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/s3v/s3v_screen.c b/src/mesa/drivers/dri/s3v/s3v_screen.c index 810232fec4..f1810597e6 100644 --- a/src/mesa/drivers/dri/s3v/s3v_screen.c +++ b/src/mesa/drivers/dri/s3v/s3v_screen.c @@ -17,6 +17,11 @@ s3vScreenPtr s3vCreateScreen( __DRIscreenPrivate *sPriv ) DEBUG(("sPriv->pDevPriv at %p\n", sPriv->pDevPriv)); DEBUG(("size = %i\n", sizeof(*vDRIPriv))); + if (sPriv->devPrivSize != sizeof(S3VDRIRec)) { + fprintf(stderr,"\nERROR! sizeof(S3VDRIRec) does not match passed size from device driver\n"); + return GL_FALSE; + } + /* Allocate the private area */ s3vScreen = (s3vScreenPtr) CALLOC( sizeof(*s3vScreen) ); if ( !s3vScreen ) return NULL; |