xlib-xcb: Fix cairo_surface_flush()

This function called directly into the xcb's surface flush function. This means
that snapshots for that surface weren't detached since that's normally done in
cairo_surface_flush() before calling into the backend.

Fix this by using surface_flush() instead of calling into the backend directly.

Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=31931

Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
Uli Schlachter 2011-07-01 21:48:31 +02:00
parent 26ee41435b
commit 7e1a9f1db0

View file

@ -196,7 +196,9 @@ static cairo_status_t
_cairo_xlib_xcb_surface_flush (void *abstract_surface)
{
cairo_xlib_xcb_surface_t *surface = abstract_surface;
return surface->xcb->base.backend->flush (surface->xcb);
/* We have to call cairo_surface_flush() to make sure snapshots are detached */
cairo_surface_flush (&surface->xcb->base);
return CAIRO_STATUS_SUCCESS;
}
static cairo_status_t