mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-05-21 14:28:10 +02:00
[cairo-xlib-surface]: flush work queue before sending glyphs to X server.
After introducing a work queue for deferred destruction of X resource my firefox crashes over and over again because XRenderFreeGlyphs is trying to free a non-exist glyph (already freed). The problematic call sequence is something like below: XRenderAddGlyphs (20990204, 20069) XRenderAddGlyphs (20990204, 20069) XRenderFreeGlyphs (20990204, 20069) XRenderFreeGlyphs (20990204, 20069) You can see the two add/free glyphs is interlaced. And obviously, we'll crash at the last one. To fix this bug, we must be ensure here's no pending work to free the glyph that we want to sent.
This commit is contained in:
parent
69bf823db1
commit
4da50dfa02
1 changed files with 1 additions and 0 deletions
|
|
@ -2887,6 +2887,7 @@ _cairo_xlib_surface_emit_glyphs (cairo_xlib_surface_t *dst,
|
|||
int request_size = 0;
|
||||
|
||||
_cairo_xlib_surface_ensure_dst_picture (dst);
|
||||
_cairo_xlib_display_notify (dst->screen_info->display);
|
||||
|
||||
for (i = 0; i < num_glyphs; i++) {
|
||||
int this_x, this_y;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue