[cairo] quartz image surface crashes because of missing call to reference (with patch)

Heiko Lewin hlewin at gmx.de
Tue Jan 5 14:16:51 UTC 2021


Hello!

I have created
https://gitlab.freedesktop.org/cairo/cairo/-/merge_requests/102 from this.

Thank you for pointing out the issue.


On 1/5/21 1:53 PM, Fred Bca wrote:
> Hi,
>
> I am not sure if it is still the process to post patches on the
> mailing list, but I hope so. The recent merge request #52
> (https://gitlab.freedesktop.org/cairo/cairo/-/merge_requests/52)
> causes crashes because of a missing call to cairo_surface_reference in
> cairo_quartz_image_surface_create (since the original surface is
> destroyed by the quartz_image_surface, it should be referenced first).
> Please find a patch below to fix the problem:
>
> --- cairo-quartz-image-surface.c
> +++ cairo-quartz-image-surface.c
> @@ -373,0 +374,2 @@ cairo_quartz_image_surface_create (cairo_surface_t
> +    // reference image surface - will be released in surface_destroy
> +    cairo_surface_reference (surface);


More information about the cairo mailing list