GNOME Bugzilla – Bug 324298
Double free of org.gnu.gdk.Window from TextView.getWindow(TextWindowType) crashes app
Last modified: 2005-12-19 15:08:16 UTC
Please describe the problem: In a situation where the user is using the gdkWindows of a TextView (say for drawing line numbers in a margin), a double free situation occurs resulting G_OBJECT_IS_OBJECT assertions failing within gtk. Steps to reproduce: 1. 2. 3. Actual results: Expected results: Does this happen every time? Other information:
Created attachment 56082 [details] [review] patch This fix stops the crash, but I'm unsure as to it's correctness. Nothing in the gtk docs indicates that we don't own a reference to the returned window, yet the symptoms of the bug seem to indicate that's the case. Will investigate further
I think it makes sense that the TextView would own the GdkWindow, even if it is not stated in the documentation. Patch looks good from my side.
Will commit above patch to CVS HEAD.