mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-01-09 18:10:25 +01:00
gstate: Prevent leak of old clip when creating a group with translation
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
8f34fa033e
commit
f84f6ecaa4
1 changed files with 1 additions and 0 deletions
|
|
@ -319,6 +319,7 @@ _cairo_gstate_redirect_target (cairo_gstate_t *gstate, cairo_surface_t *child)
|
|||
|
||||
/* The clip is in surface backend coordinates for the previous target;
|
||||
* translate it into the child's backend coordinates. */
|
||||
_cairo_clip_destroy (gstate->clip);
|
||||
gstate->clip = _cairo_clip_copy_with_translation (gstate->next->clip,
|
||||
child->device_transform.x0 - gstate->parent_target->device_transform.x0,
|
||||
child->device_transform.y0 - gstate->parent_target->device_transform.y0);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue