GNOME Bugzilla – Bug 461483
Wrong check in gtk_window_group_remove_window
Last modified: 2008-02-23 14:29:37 UTC
The type checking in gtk_window_group_remove_window looks for a GtkWidget while the argument is a GtkWindow. This leads to a critical warning when leaving Epiphany, see http://bugs.debian.org/432672
Created attachment 92642 [details] [review] Proposed patch
While I think this patch is correct, I'd like to note that this is not the cause of the crash in epiphany. (Since if it's failing the GTK_IS_WIDGET test, it's going to fail the GTK_IS_WINDOW test as well. Plus, adding a g_return_if_fail in some API function is _never_ a valid fix for a bug in an application using that API function!) The crash in epiphany is purely a debian bug, caused by the debian xulrunner package containing a buggy patch. I'm speaking of the patch from https://bugzilla.mozilla.org/show_bug.cgi?id=296002 / debian#367106; please have it removed from debian's xulrunner package.
OK, I wasn't sure of that, as on first sight I didn't see anything that could change the type of the object that is passed to gtk_window_set_transient_for. That reduces the severity of this bug.
(In reply to comment #1) > Created an attachment (id=92642) [edit] > Proposed patch please create patches with diff -up so we get the required context. bratsche,tbf, assuming the patch modifies gtk_window_group_remove_window, can you please apply, test, commit?
Seems Cody commited that patch already: commit 75b9993061e60683a8e003ee2243e1ec1682a89e Author: bratsche <bratsche@7eb1c76a-c725-0410-a3b5-a37faf6256f8> Date: Thu Aug 23 16:00:10 2007 +0000 2007-08-23 Cody Russell <bratsche@gnome.org> * gtk/gtkwindow.c (gtk_window_group_remove_window: Use the correct type check on `window'. We now check GTK_IS_WINDOW rather than GTK_IS_WIDGET. (#461483, Josselin Mouette) git-svn-id: svn+ssh://svn.gnome.org/svn/gtk+/trunk@18681 7eb1c76a-c725-0410-a3b5-a37faf6256f8
(In reply to comment #2) > The crash in epiphany is purely a debian > bug, caused by the debian xulrunner package containing a buggy patch. I'm > speaking of the patch from https://bugzilla.mozilla.org/show_bug.cgi?id=296002 > / debian#367106; please have it removed from debian's xulrunner package. Yet, this is your patch. So what is your solution for mozilla's bug (which is still not fixed after a few years) ?
(In reply to comment #6) > (In reply to comment #2) > > The crash in epiphany is purely a debian > > bug, caused by the debian xulrunner package containing a buggy patch. I'm > > speaking of the patch from https://bugzilla.mozilla.org/show_bug.cgi?id=296002 > > / debian#367106; please have it removed from debian's xulrunner package. > > Yet, this is your patch. So what? There's nothing in the upstream bug report suggesting that the patch is ready to be used; it clearly has issues beyond the crash, meriting a review-. > So what is your solution for mozilla's bug (which is > still not fixed after a few years) ? It's not my bug; it's not up to me to solve it. I don't care about that bug at all; so I'm not working on it.