clip: return empty clip from _cairo_clip_copy_rectangle_list when all_clipped

Fixes https://bugs.freedesktop.org/show_bug.cgi?id=29122
Tested by test/get-clip

Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
Karl Tomlinson 2010-07-17 10:39:50 +12:00 committed by Chris Wilson
parent 33ac203587
commit f2fa15680e

View file

@ -1499,7 +1499,10 @@ _cairo_clip_copy_rectangle_list (cairo_clip_t *clip, cairo_gstate_t *gstate)
int n_rects = 0;
int i;
if (clip != NULL && clip->path != NULL) {
if (clip->all_clipped)
goto DONE;
if (clip->path != NULL) {
status = _cairo_clip_get_region (clip, &region);
if (status == CAIRO_INT_STATUS_NOTHING_TO_DO) {
goto DONE;