xserver: Branch 'master'

Dave Airlie airlied at kemper.freedesktop.org
Sun Oct 5 23:37:20 PDT 2008


 exa/exa_glyphs.c |   14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

New commits:
commit 717c7492a0f6ba3fb3eabda33515881eef314155
Author: Dave Airlie <airlied at linux.ie>
Date:   Tue Oct 7 02:38:44 2008 +1000

    exa: don't call composite routines with no buffer.
    
    We can get a case with gnome-terminal + links, where we get two arrays
    of glyphs all with 0 width and 0 heights in them. If this happens
    we manage to get to this case without any buffer setup and segfault.

diff --git a/exa/exa_glyphs.c b/exa/exa_glyphs.c
index 2acc891..169763f 100644
--- a/exa/exa_glyphs.c
+++ b/exa/exa_glyphs.c
@@ -871,12 +871,14 @@ exaGlyphs (CARD8 	 op,
 	list++;
     }
     
-    if (maskFormat)
-	exaGlyphsToMask(pMask, &buffer);
-    else
-	exaGlyphsToDst(op, pSrc, pDst, &buffer,
-		       xSrc, ySrc, xDst, yDst);
-    
+    if (buffer.count) {
+        if (maskFormat)
+	    exaGlyphsToMask(pMask, &buffer);
+        else
+	    exaGlyphsToDst(op, pSrc, pDst, &buffer,
+		           xSrc, ySrc, xDst, yDst);
+    }
+
     if (maskFormat)
     {
 	x = extents.x1;


More information about the xorg-commit mailing list