Last Comment Bug 760047 - Don't handle a null aDocument in nsGlobalWindow::SetNewDocument
: Don't handle a null aDocument in nsGlobalWindow::SetNewDocument
Product: Core
Classification: Components
Component: DOM (show other bugs)
: Trunk
: All All
-- normal (vote)
: mozilla16
Assigned To: :Ms2ger (⌚ UTC+1/+2)
: Andrew Overholt [:overholt]
Depends on:
  Show dependency treegraph
Reported: 2012-05-31 03:51 PDT by :Ms2ger (⌚ UTC+1/+2)
Modified: 2012-06-06 03:26 PDT (History)
2 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

Patch v1 (3.57 KB, patch)
2012-05-31 03:51 PDT, :Ms2ger (⌚ UTC+1/+2)
mounir: review+
Details | Diff | Splinter Review

Description User image :Ms2ger (⌚ UTC+1/+2) 2012-05-31 03:51:06 PDT
Created attachment 628665 [details] [diff] [review]
Patch v1

All the callers null-check the document they pass, so we might as well just assert that it isn't null.
Comment 1 User image Mounir Lamouri (:mounir) 2012-05-31 05:13:20 PDT
Comment on attachment 628665 [details] [diff] [review]
Patch v1

Review of attachment 628665 [details] [diff] [review]:

I guess nsGlobalModalWindow::SetNewDocument() can't get a |null| aDocument too, right? Could you add a check there and also remove the condition for |mReturnValue = nsnull;|.

r=me with that.
Comment 2 User image :Ms2ger (⌚ UTC+1/+2) 2012-06-06 03:26:57 PDT

Note You need to log in before you can comment on or make changes to this bug.