Closed
Bug 1032427
Opened 10 years ago
Closed 9 years ago
Move docshell events to inner window only
Categories
(Core :: DOM: Core & HTML, defect)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
DUPLICATE
of bug 1182316
People
(Reporter: khuey, Assigned: khuey)
References
Details
Attachments
(1 file)
3.78 KB,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
This one is slightly tricky. There is (potentially) a behavior change here. Before if popstate caused a navigation we would end up firing the hashchange at the new inner window. That seems wrong to me, so I changed it.
Attachment #8448247 -
Flags: review?(bugs)
Comment 1•10 years ago
|
||
Comment on attachment 8448247 [details] [diff] [review]
Patch
> // The event dispatch below can cause us to re-enter script and
>- // destroy the docshell, nulling out mScriptGlobal. Hold a stack
>- // reference to avoid null derefs. See bug 914521.
>- nsRefPtr<nsGlobalWindow> win = mScriptGlobal;
>- if (win) {
>+ // destroy the docshell, nulling out mScriptGlobal or changing the
>+ // inner window. Hold a stack reference to avoid null derefs. See
>+ // bug 914521.
>+ nsCOMPtr<nsPIDOMWindow> inner =
>+ mScriptGlobal->GetCurrentInnerWindow();
Nothing guarantees mScriptGlobal is non-null here, at least in theory.
So, null check.
Attachment #8448247 -
Flags: review?(bugs) → review+
Assignee | ||
Updated•9 years ago
|
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → DUPLICATE
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•