2.8.3 crashes under IRIX [was: not compiling on IRIX... strtoull
issue?]
defreitas at gmail.com
defreitas at gmail.com
Fri May 11 08:17:46 PDT 2007
Ok... I'm going on a hunch here...
Since the call stack shows a problem in gtk_tree_view_destroy(), this
sparked my memory that I picked up a new version of src/gtk/
treeentry_gtk.c (1.6) to fix compilation warnings in IRIX about
declarations after executable statements. I don't know if this is
related, but I looked at the code differences between this new version
and the old version (1.4) and noticed on line 49 of version 1.6 that a
static variable was made into a stack variable. The code used to look
like:
__________
if (!tree_entry_type)
{
static const GTypeInfo tree_entry_info
{
sizeof (GtkTreeEntryClass),
NULL, /* base_init */
NULL, /* base_finalize */
(GClassInitFunc) gtk_tree_entry_class_init, /* class_init */
NULL, /* class_finalize */
NULL, /* class_data */
sizeof (GtkTreeEntry),
16, /* n_preallocs */
(GInstanceInitFunc) gtk_tree_entry_init, /*instance_init*/
NULL /* value_table */
};
tree_entry_type = g_type_register_static (G_TYPE_OBJECT,
"GtkTreeEntry",
&tree_entry_info,
(GTypeFlags)0);
g_value_register_transform_func(tree_entry_type, G_TYPE_STRING,
gtk_tree_entry_string_transform_func);
}
__________
In the new version, the "static" qualifier was removed from the
declaration of the variable "tree_entry_info". Now... the address of
this variable is passed into a function (which probably stores it
somewhere for later use?). This looks suspicious, since the address
will be invalid after tree_entry_info gets popped off the stack.
I put the "static" qualifier back in and unfortunately it didn't
help... so much for my hunch...
But perhaps this can spark some ideas? Any major code changes from
2.6.3 and 2.8.3 regarding the list box?
BTW, the version of gtk+ I use is: 2.0.6. Is that OK?
More information about the wx-users
mailing list