Comment 13 for bug 42683

Revision history for this message
In , Mitch (mitch-hasbox) wrote :

Created an attachment (id=164302)
patch to catch the error rather than disappearing.

Guys, this patch has been sitting in my folder for a while, so here it is in
all its glory which fixes both this bug and bug 267126 - the latter brought it
back to my memory banks.

Basically we use the gdk helper functions to catch the error instead of just
killing mozilla. We can then provide any form of dialog to warn the user that
the page will not be rendered as expected due to memory allocation faliure as a
result of bad html/javascript code. Currently (this patch) no user feedback is
given. We can do one of two things.

1. Warn that the page will not be rendered as expected and carry on as best we
can perhaps resizing image/window to sensible values not larger than screen
real estate, or

2. Abort the page loading totally - i.e. don't display a partially (in)correct
page, and provide user feedback to that effect ?

Comments before submitting for sr/r ?