image: Propagate error instead of asserting.

Apparently we can get to this point without evaluating the clip surface,
so return the error status rather than assert.
This commit is contained in:
Chris Wilson 2010-05-06 09:30:41 +01:00
parent 5e95c62bbb
commit fb6caf08ae

View file

@ -1632,7 +1632,8 @@ _cairo_image_surface_fixup_unbounded (cairo_image_surface_t *dst,
int clip_x, clip_y;
clip_surface = _cairo_clip_get_surface (clip, &dst->base, &clip_x, &clip_y);
assert (clip_surface->status == CAIRO_STATUS_SUCCESS);
if (unlikely (clip_surface->status))
return clip_surface->status;
mask = ((cairo_image_surface_t *) clip_surface)->pixman_image;
mask_x = -clip_x;