pixman: Branch 'master' - 5 commits
Søren Sandmann Pedersen
sandmann at kemper.freedesktop.org
Wed Aug 1 12:23:59 PDT 2012
pixman/Makefile.am | 1 +
pixman/make-srgb.pl | 5 ++++-
pixman/pixman-matrix.c | 2 +-
test/glyph-test.c | 4 ++--
test/stress-test.c | 5 +++++
5 files changed, 13 insertions(+), 4 deletions(-)
New commits:
commit c214ca51a00fdd0e773ace32076c3ed8a5d0d482
Author: Sebastian Bauer <mail at sebastianbauer.info>
Date: Tue Jul 31 07:30:32 2012 +0200
Use angle brackets form of including config.h
diff --git a/pixman/pixman-matrix.c b/pixman/pixman-matrix.c
index 6d215ff..a029ab7 100644
--- a/pixman/pixman-matrix.c
+++ b/pixman/pixman-matrix.c
@@ -25,7 +25,7 @@
*/
#ifdef HAVE_CONFIG_H
-#include "config.h"
+#include <config.h>
#endif
#include <math.h>
commit 98617b3796d12c18d8306cca590160caa3c95454
Author: Sebastian Bauer <mail at sebastianbauer.info>
Date: Tue Jul 31 07:30:31 2012 +0200
Added HAVE_CONFIG_H check before including config.h
diff --git a/pixman/make-srgb.pl b/pixman/make-srgb.pl
index ebde2ea..cdaa80b 100644
--- a/pixman/make-srgb.pl
+++ b/pixman/make-srgb.pl
@@ -72,7 +72,10 @@ print <<"PROLOG";
#include <stdint.h>
-#include "config.h"
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
#include "pixman-private.h"
PROLOG
commit 5b0563f39eb29e4ae431717696174da5e282c346
Author: Søren Sandmann Pedersen <ssp at redhat.com>
Date: Mon Jul 30 16:21:39 2012 -0400
glyph-test: Avoid setting solid images as alpha maps.
glyph-test would sometimes set a solid image as an alpha map, which is
not allowed. When this happened and the debug spew was enabled,
messages like this one would be generated:
*** BUG ***
In pixman_image_set_alpha_map: The expression
!alpha_map || alpha_map->type == BITS was false
Set a breakpoint on '_pixman_log_error' to debug
Fix this by not passing the ALLOW_SOLID flag to create_image() when
the resulting is to be used as an alpha map.
diff --git a/test/glyph-test.c b/test/glyph-test.c
index 0fb6641..84de5aa 100644
--- a/test/glyph-test.c
+++ b/test/glyph-test.c
@@ -199,7 +199,7 @@ create_image (int max_size, const pixman_format_code_t *formats, uint32_t flags)
alpha_x = lcg_rand_n (width);
alpha_y = lcg_rand_n (height);
alpha_map =
- create_image (max_size, formats, (flags & ~ALLOW_ALPHA_MAP));
+ create_image (max_size, formats, (flags & ~(ALLOW_ALPHA_MAP | ALLOW_SOLID)));
pixman_image_set_alpha_map (image, alpha_map, alpha_x, alpha_y);
pixman_image_unref (alpha_map);
}
@@ -330,6 +330,6 @@ int
main (int argc, const char *argv[])
{
return fuzzer_test_main ("glyph", 30000,
- 0x1B7696A2,
+ 0x741CB2DB,
test_glyphs, argc, argv);
}
commit 38fe7cd7be388aae6dff7d9b9979eb4ffa5fa175
Author: Søren Sandmann Pedersen <ssp at redhat.com>
Date: Mon Jul 30 16:10:05 2012 -0400
stress-test: Avoid overflows in clip rectangles
The rectangles in the clip region set in set_general_properties()
would sometimes overflow, which would lead to messages like these:
*** BUG ***
In pixman_region32_union_rect: Invalid rectangle passed
Set a breakpoint on '_pixman_log_error' to debug
when the micro version number of pixman is even.
Fix this by detecting the overflow and clamping such that the x2/y2
coordinates are less than INT32_MAX.
diff --git a/test/stress-test.c b/test/stress-test.c
index 54ab1c5..edcfe09 100644
--- a/test/stress-test.c
+++ b/test/stress-test.c
@@ -468,6 +468,11 @@ set_general_properties (pixman_image_t *image, pixman_bool_t allow_alpha_map)
width = lcg_rand_n (image->bits.width) - x + 10;
height = lcg_rand_n (image->bits.height) - y + 10;
+ if (width + x < x)
+ width = INT32_MAX - x;
+ if (height + y < y)
+ height = INT32_MAX - y;
+
pixman_region32_union_rect (
®ion, ®ion, x, y, width, height);
}
commit 24d83cbf3df06505fa4cf827271aa2985414cfdd
Author: Søren Sandmann Pedersen <ssp at redhat.com>
Date: Mon Jul 30 15:54:27 2012 -0400
Add make-srgb.pl to EXTRA_DIST
Otherwise make distcheck doesn't pass.
diff --git a/pixman/Makefile.am b/pixman/Makefile.am
index deacf87..843711a 100644
--- a/pixman/Makefile.am
+++ b/pixman/Makefile.am
@@ -13,6 +13,7 @@ noinst_LTLIBRARIES =
EXTRA_DIST = \
Makefile.win32 \
make-combine.pl \
+ make-srgb.pl \
pixman-combine.c.template \
pixman-combine.h.template \
pixman-region.c \
More information about the xorg-commit
mailing list