xf86-video-intel: src/i830_uxa.c

Chris Wilson ickle at kemper.freedesktop.org
Wed Mar 24 11:29:13 PDT 2010


 src/i830_uxa.c |    9 +++++++++
 1 file changed, 9 insertions(+)

New commits:
commit 0c47195ca805881e3fbd5b9224be5c930feeeb8c
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Wed Mar 24 17:37:39 2010 +0000

    i830: Clip solid fills to surface.
    
    There is a reasonable surfeit of evidence to support this error,
    for instance: http://bugs.freedesktop.org/attachment.cgi?id=34417
    
    Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

diff --git a/src/i830_uxa.c b/src/i830_uxa.c
index 22792fe..3af4042 100644
--- a/src/i830_uxa.c
+++ b/src/i830_uxa.c
@@ -264,6 +264,15 @@ static void i830_uxa_solid(PixmapPtr pixmap, int x1, int y1, int x2, int y2)
 	unsigned long pitch;
 	uint32_t cmd;
 
+	if (x1 < 0)
+		x1 = 0;
+	if (y1 < 0)
+		y1 = 0;
+	if (x2 > pixmap->drawable.width)
+		x2 = pixmap->drawable.width;
+	if (y2 > pixmap->drawable.height)
+		y2 = pixmap->drawable.height;
+
 	pitch = i830_pixmap_pitch(pixmap);
 
 	{


More information about the xorg-commit mailing list