Open Bug 1425702 Opened 6 years ago Updated 8 months ago

clear mIsTopLevelContentDocument / mIsContentDocument when a document is removed from a docshell


(Core :: DOM: Core & HTML, enhancement, P2)





(Reporter: heycam, Unassigned)



(2 files)

Currently once these flags are set, they remain set forever.
Priority: -- → P2
Comment on attachment 8937299 [details]
Bug 1425702 - Part 1: Add some docs for nsIDocument::{mIsTopLevelContentDocument,mIsContentDocument}.
Attachment #8937299 - Flags: review?(bzbarsky) → review+
Comment on attachment 8937300 [details]
Bug 1425702 - Part 2: Reset nsIDocument::{mIsTopLevelContentDocument,mIsContentDocument} when a document is removed from its docshell.

This doesn't look right to me.  In particular, ReportUseCounters() uses these members and is called in nsDocument::~nsDocument, which presumably comes after we SetContainer(nullptr).
Attachment #8937300 - Flags: review?(bzbarsky) → review-
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.