On Tue, 8 Mar 2016 22:45:02 +0100
Rhialto <[email protected]> wrote:
(...)
> This is a simple one because this is the source:
>
> 1639 gtk_container_remove (GTK_CONTAINER (_att_frame), _att_toolbar);
> 1640 if (G_IS_OBJECT(_att_toolbar)) g_object_unref(_att_toolbar);
>
> where the object is deleted at 1639 and touched again in 1640.
>
> It turns out that the manual says that gtk_container_remove() may delete
> the object if the refcount drops to zero. Which seems to happen here
> since I found nothing to increase it (and I presume that on allocation
> in line 1701 it starts out with 1). So removing the second line would
> fix this issue.
>
> Not all are this simple, but it is a good help :)
Thanks for all the info, Olaf! So this patch will do?
--- /tmp/ezzIwP_body-pane.cc
+++ /tmp/pan2/pan/gui/body-pane.cc
@@ -1637,7 +1637,6 @@
{
gtk_container_remove (GTK_CONTAINER (_att_frame), _att_toolbar);
- if (G_IS_OBJECT(_att_toolbar)) g_object_unref(_att_toolbar);
(void)create_attachments_toolbar(_att_frame);
}
--
pk
_______________________________________________
Pan-users mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/pan-users