From 2b5d9c8e007f4198b1c48bce53491842f065a759 Mon Sep 17 00:00:00 2001 From: Carl Worth Date: Wed, 27 Jul 2005 15:39:34 +0000 Subject: Add CAIRO_STATUS_INVALID_CONTENT, CAIRO_STATUS_INVALID_FORMAT, and CAIRO_STATUS_INVALID_VISUAL. Change functions to return type of void: cairo_scaled_font_extents cairo_surface_finish Add new functions to query object status: cairo_scaled_font_status cairo_surface_status Implementation of new error handling scheme for cairo_surface_t and cairo_scaled_font_t. Track change in return value of cairo_surface_finish. --- src/cairo-array.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/cairo-array.c') diff --git a/src/cairo-array.c b/src/cairo-array.c index a9f148a0..ef7f77fc 100644 --- a/src/cairo-array.c +++ b/src/cairo-array.c @@ -198,6 +198,11 @@ _cairo_user_data_array_get_data (cairo_user_data_array_t *array, int i, num_slots; cairo_user_data_slot_t *slots; + /* We allow this to support degenerate objects such as + * cairo_image_surface_nil. */ + if (array == NULL) + return NULL; + num_slots = array->num_elements; slots = (cairo_user_data_slot_t *) array->elements; for (i = 0; i < num_slots; i++) { -- cgit v1.2.3