summaryrefslogtreecommitdiff
path: root/src/cairo-quartz-surface.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/cairo-quartz-surface.c')
-rw-r--r--src/cairo-quartz-surface.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/cairo-quartz-surface.c b/src/cairo-quartz-surface.c
index af92c01..70f408a 100644
--- a/src/cairo-quartz-surface.c
+++ b/src/cairo-quartz-surface.c
@@ -152,7 +152,8 @@ _cairo_quartz_surface_acquire_dest_image(void *abstract_surface,
image_rect->height = surface->image->height;
*image_out = surface->image;
- *image_extra = NULL;
+ if (image_extra)
+ *image_extra = NULL;
return CAIRO_STATUS_SUCCESS;
}
@@ -233,7 +234,7 @@ cairo_surface_t *cairo_quartz_surface_create(CGContextRef context,
surface = malloc(sizeof(cairo_quartz_surface_t));
if (surface == NULL) {
_cairo_error (CAIRO_STATUS_NO_MEMORY);
- return &_cairo_surface_nil;
+ return (cairo_surface_t*) &_cairo_surface_nil;
}
_cairo_surface_init(&surface->base, &cairo_quartz_surface_backend);