Closed Bug 1315796 Opened 8 years ago Closed 8 years ago

TabGroup DEBUG validation code can try to use null docshell

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla52
Tracking Status
firefox52 --- fixed

People

(Reporter: bkelly, Assigned: bkelly)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

In the TabGroupOuter() method there is some validation code.  It can try to use a nullptr docshell causing weird behavior.
Comment on attachment 8808365 [details] [diff] [review]
Don't deref nullptr docshell in TabGroupOuter() validation code. r=smaug

http://searchfox.org/mozilla-central/source/dom/base/nsGlobalWindow.h#2065
http://searchfox.org/mozilla-central/source/docshell/base/nsDocShell.cpp#13260

So, I think you should just check mIsChrome in the 'if'. No need to use docshell at all.
with that, r+
Attachment #8808365 - Flags: review?(bugs) → review+
Pushed by bkelly@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/fc00f40f2b6e
Don't deref nullptr docshell in TabGroupOuter() validation code. r=smaug
Blocks: 1315803
https://hg.mozilla.org/mozilla-central/rev/fc00f40f2b6e
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla52
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: