GNOME Bugzilla – Bug 334438
suspicious free in gailcombobox.c
Last modified: 2006-03-14 19:52:35 UTC
gailcombobox.c:244: combo_box = GTK_COMBO_BOX (widget); gail_combo_box = GAIL_COMBO_BOX (obj); g_free (gail_combo_box->name); if (gtk_combo_box_get_active_iter (combo_box, &iter)) The free is bogus since we then return gail_combo_box->name unconditionally, even if we don't execute the codepath which assigns a new value. Instead we should explicitly g_strdup() the string value and g_free() the name in the same block, and use g_value_unset() to clean up the GValue struct used to obtain the name string.
Created attachment 61241 [details] [review] patch to fix the way the g_free is done, and only free when replacing the value.
Thanks Bill! This seems to fix a crasher in the Evolution first run wizard.