mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-05-01 09:07:58 +02:00
mask compositor: Set a check_composite method
Commit 503b6b9e2e added a check_composite method to the mask compositor, but
only added it to one of the existing implementations. This commit fixes that.
In cairo-image-compositor.c, there is already a check_composite method which
just returns success for the traps compositor. This commit makes the mask
compositor use that one.
I don't want to say much about cairo-image-mask-compositor.c except that I
wondered why this file and the file above both define a non-static function
called _cairo_image_mask_compositor_get(). In my opinion, that file should just
be deleted, since it confuses e.g. ctags, but I'll let someone else clean this
up.
Fixes 493 crashes in the test suite for the test-mask target.
Signed-off-by: Uli Schlachter <psychon@znc.in>
Tested-by: Bryce Harrington <b.harrington@samsung.com>
This commit is contained in:
parent
17e14b62e0
commit
5b083237f5
2 changed files with 4 additions and 1 deletions
|
|
@ -1257,7 +1257,7 @@ _cairo_image_mask_compositor_get (void)
|
|||
compositor.draw_image_boxes = draw_image_boxes;
|
||||
compositor.fill_rectangles = fill_rectangles;
|
||||
compositor.fill_boxes = fill_boxes;
|
||||
//compositor.check_composite = check_composite;
|
||||
compositor.check_composite = check_composite;
|
||||
compositor.composite = composite;
|
||||
//compositor.lerp = lerp;
|
||||
//compositor.check_composite_boxes = check_composite_boxes;
|
||||
|
|
|
|||
|
|
@ -48,6 +48,8 @@
|
|||
#include "cairo-compositor-private.h"
|
||||
#include "cairo-region-private.h"
|
||||
|
||||
#error This file isn't included in any Makefile
|
||||
|
||||
static cairo_int_status_t
|
||||
acquire (void *abstract_dst)
|
||||
{
|
||||
|
|
@ -398,6 +400,7 @@ _cairo_image_mask_compositor_get (void)
|
|||
compositor.draw_image = draw_image;
|
||||
compositor.fill_rectangles = fill_rectangles;
|
||||
compositor.fill_boxes = fill_boxes;
|
||||
#error check_composite must never be NULL, because it gets called without a NULL pointer check
|
||||
//compositor.check_composite = check_composite;
|
||||
compositor.composite = composite;
|
||||
//compositor.check_composite_boxes = check_composite_boxes;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue