pan-users
[Top][All Lists]
Advanced

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

Re: [Pan-users] Pan bug 712539 and 757672


From: Petr Kovar
Subject: Re: [Pan-users] Pan bug 712539 and 757672
Date: Wed, 9 Mar 2016 22:42:26 +0100

On Tue, 8 Mar 2016 22:45:02 +0100
Rhialto <address@hidden> 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



reply via email to

[Prev in Thread] Current Thread [Next in Thread]