Fixes FwNULL 6/16 & 7/16 & 8/16
[modest] / src / hildon2 / modest-msg-view-window.c
index 280a3ff..f34f2b6 100644 (file)
@@ -2481,7 +2481,8 @@ modest_msg_view_window_view_attachment (ModestMsgViewWindow *window,
                        mime_part = (TnyMimePart *) tny_iterator_get_current (iter);
                        g_object_unref (iter);
                }
-               g_object_unref (selected_attachments);
+               if (selected_attachments)
+                       g_object_unref (selected_attachments);
 
                if (error)
                        goto frees;