GtkTreeview remove_expand_collapse_timeout crash
Submitted by mat..@..il.com
Assigned to gtk..@..tk.org
Link to original bug (#782809)
Description
Operating system is Solaris (SunOS), though I suspect that it's something that affects Linux as well.
When bug 511217 was worked remove_expand_collapse_timeout was added, in this call the following line is causing a crash when using GLIB versions 2.39 and up:
gtk/treeview.c::remove_expand_collapse_timeout (line 11910) "g_source_remove(tree_view->priv->expand_collapse_timeout)"
Glib 2.39 made a change wherein attempting to call g_source_remove on a non-existent source will throw a Critical Error and terminate the program with SIGABRT. This is accompanied by the following error in g_log when it occurs: "Source ID %u was not found when attempting to remove it.".
To reproduce: Populate a treeview using GTK+2 (2.24.x) and GLIB (2.39+) with expandable/collapsible rows. Click on the arrow to collapse the row, then click on an arrow to again expand it. The application should crash and leave a core with the aforementioned error visible in stack from g_log.
Unsure of why it's attempting to call g_source_remove on a nonexistent source, though it could have just never been a consideration since the code was introduced in 2008, and GTK+3 solved this by replacing the code in 2011 in version 2.99 (a full 2 years before GLIB 2.39 was released in 2013).
Version: 2.24.x