From afbfb6405d63b196960a2acc5f3a12f2d3f1686a Mon Sep 17 00:00:00 2001
From: Siarhei Siamashka <siarhei.siamashka@nokia.com>
Date: Mon, 20 Apr 2009 16:32:14 +0300
Subject: [PATCH] Removed unnecessary processing of undefined byte for x8r8b8g8 format

Top 8 bits of x8r8g8b8 format are undefined as explained in:
http://lists.cairographics.org/archives/cairo/2009-April/016902.html
---
 pixman/pixman-pict.c |    8 +++-----
 1 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/pixman/pixman-pict.c b/pixman/pixman-pict.c
index 46a102e..bb1a365 100644
--- a/pixman/pixman-pict.c
+++ b/pixman/pixman-pict.c
@@ -622,7 +622,7 @@ fbCompositeSrc_8888x8888 (pixman_op_t op,
 			 uint16_t     width,
 			 uint16_t     height)
 {
-    uint32_t	*dstLine, *dst, dstMask;
+    uint32_t	*dstLine, *dst;
     uint32_t	*srcLine, *src, s;
     int	dstStride, srcStride;
     uint8_t	a;
@@ -631,8 +631,6 @@ fbCompositeSrc_8888x8888 (pixman_op_t op,
     fbComposeGetStart (pDst, xDst, yDst, uint32_t, dstStride, dstLine, 1);
     fbComposeGetStart (pSrc, xSrc, ySrc, uint32_t, srcStride, srcLine, 1);
 
-    dstMask = FbFullMask (PIXMAN_FORMAT_DEPTH (pDst->bits.format));
-
     while (height--)
     {
 	dst = dstLine;
@@ -646,9 +644,9 @@ fbCompositeSrc_8888x8888 (pixman_op_t op,
 	    s = READ(pSrc, src++);
 	    a = s >> 24;
 	    if (a == 0xff)
-		WRITE(pDst, dst, s & dstMask);
+		WRITE(pDst, dst, s);
 	    else
-		WRITE(pDst, dst, fbOver (s, READ(pDst, dst)) & dstMask);
+		WRITE(pDst, dst, fbOver (s, READ(pDst, dst)));
 	    dst++;
 	}
     }
-- 
1.5.6.5

