Gene Auyeung <quaker4...@gmail.com> writes:

> Hi,
>
> For a while I've been frustrated when I close a surf window, it takes
> down the process that created it, along with all windows of that
> process.  For clicking a link in gmail will open a new window, and
> closing that window sometimes closes the parent window as well.  Today
> I had some time to insert printfs into surf.c to find out what's going
> on.

I posted a patch to fix this some time ago.  There are three similar
issues as far as I know:

 * When destroying a surf window, you will often end up with a situation
   in which you are in mid-takedown and have destroyed the progress bar,
   yet an event that wishes to update the progress bar will arrive.
   This will usually crash due to a BadWindow error.  This can be fixed
   by disabling signals in the destroyclient function:

     g_signal_handlers_disconnect_matched(GTK_WIDGET(c->view), 
G_SIGNAL_MATCH_DATA, 0, 0, 0, 0, c);

 * Something similar to the above, although harder to fix, in which some
   internal part of WebKit is not done with its work by the time you
   g_free() it.  I have not been able to figure out a way to fix this.

 * Fucking modules like Flash and Java not dealing well with being
   closed, resulting in BadWindow errors similar to the first problem.

I advocate simple adding an X11 error handler that ignores BadWindow
errors.  This seems like a pretty standard way to do it.

-- 
\  Troels
/\ Henriksen

Reply via email to