summaryrefslogtreecommitdiff
path: root/src/cairo-clip-private.h
diff options
context:
space:
mode:
authorAndrea Canciani <ranma42@gmail.com>2011-03-18 16:10:39 +0100
committerAndrea Canciani <ranma42@gmail.com>2011-03-18 17:54:54 +0100
commitf2eb3f2178b6b7a75da4fb5e5bd880b769b69e62 (patch)
treea48a28a3341aea2cdecfa1580af76899b4950c61 /src/cairo-clip-private.h
parent7db5e3fdc8ea368547bb0b8f15d190c4f6891e20 (diff)
Improve cairo_rectangle_list_t error handling
Unify the _cairo_rectangle_list_create_in_error() functions, keeping the best features from both (the one in cairo-clip.c statically allocates the most common cases, the one in cairo.c throws a NO_MEMORY error when it cannot malloc() instead of rethrowing the same error). The same function can be used to return an error-list in _cairo_gstate_copy_clip_rectangle_list() when _cairo_clip_rectangle() fails (for example becaouse of an OOM).
Diffstat (limited to 'src/cairo-clip-private.h')
-rw-r--r--src/cairo-clip-private.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/cairo-clip-private.h b/src/cairo-clip-private.h
index faf486409..bfbb539aa 100644
--- a/src/cairo-clip-private.h
+++ b/src/cairo-clip-private.h
@@ -148,4 +148,7 @@ _cairo_clip_drop_cache (cairo_clip_t *clip);
cairo_private cairo_rectangle_list_t*
_cairo_clip_copy_rectangle_list (cairo_clip_t *clip, cairo_gstate_t *gstate);
+cairo_private cairo_rectangle_list_t *
+_cairo_rectangle_list_create_in_error (cairo_status_t status);
+
#endif /* CAIRO_CLIP_PRIVATE_H */