summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pixman/ChangeLog.libic5
-rw-r--r--pixman/src/ictrap.c3
2 files changed, 8 insertions, 0 deletions
diff --git a/pixman/ChangeLog.libic b/pixman/ChangeLog.libic
index 29f3c120..dc023892 100644
--- a/pixman/ChangeLog.libic
+++ b/pixman/ChangeLog.libic
@@ -1,3 +1,8 @@
+2003-05-05 Carl Worth <cworth@isi.edu>
+
+ * src/ictrap.c (IcCompositeTrapezoids): Avoid crash if there's
+ nothing to draw.
+
2003-04-26 Carl Worth <cworth@isi.edu>
* src/icimage.c (IcImageDestroy): Fix memory leak of image->pixels
diff --git a/pixman/src/ictrap.c b/pixman/src/ictrap.c
index 160e1965..c6216c28 100644
--- a/pixman/src/ictrap.c
+++ b/pixman/src/ictrap.c
@@ -121,6 +121,9 @@ IcCompositeTrapezoids (char op,
INT16 xDst, yDst;
INT16 xRel, yRel;
IcFormat *format;
+
+ if (ntraps == 0)
+ return;
xDst = traps[0].left.p1.x >> 16;
yDst = traps[0].left.p1.y >> 16;