Re: Valgrind errors with UIManager

On 12/10/2008 09:47 AM, Alexander Shaduri wrote:
The bound refptr is taking an additional reference on the Action object and so that object
is staying alive longer than it normally would.  One theory is that when the Action object
does finally get destroyed in the TestWindow destructor, some piece of GTK+ data that it
depended on might have already been destroyed, resulting in the warnings you see.

Thanks for the reply!

(Taking this message back to the mailing list, I hope it's ok with you).

Oh, sorry, did I accidentally take the response off-list?

I changed the callback so that it would fetch the Action object from
an associative (action_t ->  Action) map, which I made TestWindow's member.
Everything seems to work just fine now.
Just binding Gtk::Action* also seemed to work (I had to use
action.operator->() to get that type).

Anyway, the workaround is known now, thanks for your help!

I wonder if it's a bug in gtkmm/gtk, or just undocumented behaviour.
Should I file a bug report?

It certainly wouldn't hurt.


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