From f20814e07e7032c14f273d712f35e19addfdae80 Mon Sep 17 00:00:00 2001 From: Andrea Canciani Date: Tue, 5 Oct 2010 10:36:38 +0200 Subject: [PATCH] xcb: Do not return value in void function Sun Studio Compiler complains: "cairo-xcb-surface.c", line 585: void function cannot return value even if the returned value is void. Some minor code restructuring removes the issue. --- src/cairo-xcb-surface.c | 10 ++++------ 1 files changed, 4 insertions(+), 6 deletions(-) diff --git a/src/cairo-xcb-surface.c b/src/cairo-xcb-surface.c index 9c2d3a7..d852f50 100644 --- a/src/cairo-xcb-surface.c +++ b/src/cairo-xcb-surface.c @@ -580,12 +580,10 @@ _cairo_xcb_surface_release_source_image (void *abstract_surface, { cairo_xcb_surface_t *surface = abstract_surface; - if (surface->drm != NULL && ! surface->marked_dirty) { - return _cairo_surface_release_source_image (surface->drm, - image, image_extra); - } - - cairo_surface_destroy (&image->base); + if (surface->drm != NULL && !surface->marked_dirty) + _cairo_surface_release_source_image (surface->drm, image, image_extra); + else + cairo_surface_destroy (&image->base); } static cairo_bool_t -- 1.7.1