summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/common/dri_util.c6
-rw-r--r--src/mesa/drivers/dri/common/dri_util.h4
2 files changed, 8 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c
index 9a8d247e592..13101755b3e 100644
--- a/src/mesa/drivers/dri/common/dri_util.c
+++ b/src/mesa/drivers/dri/common/dri_util.c
@@ -826,7 +826,13 @@ static void *driCreateNewDrawable(Display *dpy,
pdp->getInfo = (GetDrawableInfo *)
glXGetProcAddress( (const GLubyte *) "__glXGetDrawableInfo" );
if ( pdp->getInfo == NULL ) {
+#ifdef DRI_NEW_INTERFACE_ONLY
+ (void)XF86DRIDestroyDrawable(dpy, modes->screen, pdp->draw);
+ Xfree(pdp);
+ return NULL;
+#else
pdp->getInfo = XF86DRIGetDrawableInfo;
+#endif /* DRI_NEW_INTERFACE_ONLY */
}
if (!(*psp->DriverAPI.CreateBuffer)(psp, pdp, modes,
diff --git a/src/mesa/drivers/dri/common/dri_util.h b/src/mesa/drivers/dri/common/dri_util.h
index 627a58562a5..17f26d1a210 100644
--- a/src/mesa/drivers/dri/common/dri_util.h
+++ b/src/mesa/drivers/dri/common/dri_util.h
@@ -257,9 +257,9 @@ struct __DRIswapInfoRec {
typedef Bool (GetDrawableInfo)( Display *dpy, int scrn, __DRIid draw,
unsigned int * index, unsigned int * stamp,
int * x, int * y, int * width, int * height,
- int * numClipRects, drm_clip_rect_t * pClipRects,
+ int * numClipRects, drm_clip_rect_t ** pClipRects,
int * backX, int * backY,
- int * numBackClipRects, drm_clip_rect_t * pBackClipRects );
+ int * numBackClipRects, drm_clip_rect_t ** pBackClipRects );
/**