Skip to content

Commit

Permalink
xcb: Correctly check for image surface for inplace upload
Browse files Browse the repository at this point in the history
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=82987
Signed-off-by: Uli Schlachter <psychon@znc.in>
  • Loading branch information
Uli Schlachter committed Aug 23, 2014
1 parent 183ac18 commit 545444e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/cairo-xcb-surface-render.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
#include "cairo-clip-inline.h"
#include "cairo-clip-private.h"
#include "cairo-composite-rectangles-private.h"
#include "cairo-image-surface-inline.h"
#include "cairo-image-surface-private.h"
#include "cairo-list-inline.h"
#include "cairo-region-private.h"
Expand Down Expand Up @@ -2786,7 +2787,7 @@ _upload_image_inplace (cairo_xcb_surface_t *surface,
return CAIRO_INT_STATUS_UNSUPPORTED;

pattern = (const cairo_surface_pattern_t *) source;
if (pattern->surface->type != CAIRO_SURFACE_TYPE_IMAGE)
if (! _cairo_surface_is_image (pattern->surface))
return CAIRO_INT_STATUS_UNSUPPORTED;

/* Have we already upload this image to a pixmap? */
Expand Down

0 comments on commit 545444e

Please sign in to comment.