[PATCH] mi: Add some sanity checking to miPaintWindow

Jeremy Huddleston jeremyhu at apple.com
Wed Apr 21 08:43:18 PDT 2010



Signed-off-by: Jeremy Huddleston <jeremyhu at apple.com>
---
 mi/miexpose.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/mi/miexpose.c b/mi/miexpose.c
index 1c9c3a4..1a7cd0c 100644
--- a/mi/miexpose.c
+++ b/mi/miexpose.c
@@ -551,6 +551,9 @@ miPaintWindow(WindowPtr pWin, RegionPtr prgn, int what)
     Bool	solid = TRUE;
     DrawablePtr	drawable = &pWin->drawable;
 
+    if(!drawable || drawable->type == UNDRAWABLE_WINDOW)
+	return;
+
 #ifdef ROOTLESS
     if(IsFramedWindow(pWin)) {
         RootlessStartDrawing(pWin);
-- 
1.7.0.4




More information about the xorg-devel mailing list