[gthumb] fixed crash when viewing a broken image



commit 85a2ce84de9c614e334bd7229c7c170c12beffd5
Author: Paolo Bacchilega <paobac src gnome org>
Date:   Sat Oct 12 20:04:43 2013 +0200

    fixed crash when viewing a broken image

 gthumb/gth-image.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/gthumb/gth-image.c b/gthumb/gth-image.c
index fd5627f..020c468 100644
--- a/gthumb/gth-image.c
+++ b/gthumb/gth-image.c
@@ -345,6 +345,9 @@ gth_image_get_pixbuf_animation (GthImage *image)
 gboolean
 gth_image_get_is_animation (GthImage *image)
 {
+       if (image == NULL)
+               return FALSE;
+
        return ((image->priv->format == GTH_IMAGE_FORMAT_GDK_PIXBUF_ANIMATION)
                && (! gdk_pixbuf_animation_is_static_image (image->priv->data.pixbuf_animation)));
 }


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