[gtk+] blur: Simplify return_if_fail()



commit 98ee594f7347e363834bffbec7320c71ac18637e
Author: Benjamin Otte <otte redhat com>
Date:   Tue Feb 3 08:06:39 2015 +0100

    blur: Simplify return_if_fail()

 gtk/gtkcairoblur.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)
---
diff --git a/gtk/gtkcairoblur.c b/gtk/gtkcairoblur.c
index 29bc168..406e09b 100644
--- a/gtk/gtkcairoblur.c
+++ b/gtk/gtkcairoblur.c
@@ -194,14 +194,11 @@ void
 _gtk_cairo_blur_surface (cairo_surface_t* surface,
                          double           radius_d)
 {
-  cairo_format_t format;
   int radius = radius_d;
 
   g_return_if_fail (surface != NULL);
   g_return_if_fail (cairo_surface_get_type (surface) == CAIRO_SURFACE_TYPE_IMAGE);
-
-  format = cairo_image_surface_get_format (surface);
-  g_return_if_fail (format == CAIRO_FORMAT_A8);
+  g_return_if_fail (cairo_image_surface_get_format (surface) == CAIRO_FORMAT_A8);
 
   if (radius == 0)
     return;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]