Skip to content

Commit

Permalink
_cairo_xcb_surface_ensure_picture: Check fallback
Browse files Browse the repository at this point in the history
When an XCB surface's fallback member is not NULL, we did some rendering that
the X server couldn't do for us and thus did that internally in cairo instead.
This means the X drawable's content is out of date and should not be used for
drawing anything.

This adds an assert which checks for that situation.

Signed-off-by: Uli Schlachter <psychon@znc.in>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
  • Loading branch information
Uli Schlachter authored and Chris Wilson committed Oct 13, 2010
1 parent 35b1688 commit 5a0f8f7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/cairo-xcb-surface-render.c
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,7 @@ static void
_cairo_xcb_surface_ensure_picture (cairo_xcb_surface_t *surface)
{
if (surface->picture == XCB_NONE) {
assert (surface->fallback == NULL);
surface->picture = _cairo_xcb_connection_get_xid (surface->connection);
_cairo_xcb_connection_render_create_picture (surface->connection,
surface->picture,
Expand Down

0 comments on commit 5a0f8f7

Please sign in to comment.