[gimp/metadata-browser] app: silence a harmless Gimp-Core-CRITICAL
- From: Roman Joost <romanofski src gnome org>
- To: commits-list gnome org
- Cc: 
- Subject: [gimp/metadata-browser] app: silence a harmless Gimp-Core-CRITICAL
- Date: Wed, 12 Sep 2012 22:15:00 +0000 (UTC)
commit cffc2c1dc03836efc2f20414460881553a100afe
Author: Massimo Valentini <mvalentini src gnome org>
Date:   Fri Nov 18 18:36:00 2011 +0100
    app: silence a harmless Gimp-Core-CRITICAL
    
    Dragging a channel preview (not RGBA) over a layer preview
    GIMP used to print:
    
    Gimp-Core-CRITICAL **: gimp_container_get_child_index: ...
               assertion `GIMP_IS_CONTAINER (container)' failed
 app/widgets/gimpcontainertreeview-dnd.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/app/widgets/gimpcontainertreeview-dnd.c b/app/widgets/gimpcontainertreeview-dnd.c
index 4183b6d..91367e6 100644
--- a/app/widgets/gimpcontainertreeview-dnd.c
+++ b/app/widgets/gimpcontainertreeview-dnd.c
@@ -520,8 +520,9 @@ gimp_container_tree_view_real_drop_possible (GimpContainerTreeView   *tree_view,
       else if (gimp_container_have (container, GIMP_OBJECT (src_viewable)))
         src_container = container;
 
-      src_index = gimp_container_get_child_index (src_container,
-                                                  GIMP_OBJECT (src_viewable));
+      if (src_container)
+        src_index = gimp_container_get_child_index (src_container,
+                                                    GIMP_OBJECT (src_viewable));
     }
 
   if (dest_viewable)
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]