[PATCH v2 02/10] dri2: Refactor interface to take DRIDrawablePtr

Pauli ext-pauli.nieminen at nokia.com
Wed Feb 16 02:21:35 PST 2011


From: Pauli Nieminen <ext-pauli.nieminen at nokia.com>

Original patch has NULL pointer deference bug which I have fixed locally with
following patch. 

---
 hw/xfree86/dri2/dri2.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/xfree86/dri2/dri2.c b/hw/xfree86/dri2/dri2.c
index 39e64db..db9722c 100644
--- a/hw/xfree86/dri2/dri2.c
+++ b/hw/xfree86/dri2/dri2.c
@@ -506,8 +506,8 @@ do_get_buffers(DRI2DrawablePtr pPriv, int *width, int *height,
     int i;
 
     if (!pDraw) {
-	*width = pDraw->width;
-	*height = pDraw->height;
+	*width = pPriv->width;
+	*height = pPriv->height;
 	*out_count = 0;
 	return NULL;
     }
-- 
1.7.0.4



More information about the xorg-devel mailing list