Closed Bug 341551 Opened 20 years ago Closed 20 years ago

document.write() without document.close() in popup: ###!!! ASSERTION: EndLoad called early: 'mWriteState == eNotWriting || mWriteState == ePendingClose || mWriteState == eDocumentClosed', file c:/mozilla.org/baseline/mozilla/content

Categories

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

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 332896

People

(Reporter: WeirdAl, Assigned: mrbkap)

References

Details

(Keywords: assertion, testcase)

Steps to reproduce: (1) SeaMonkey trunk, load https://bugzilla.mozilla.org/attachment.cgi?id=133934 (from bug 223393) (2) Close the popup window. I claim this assertion is bogus; although document.close() dates back to DOM Level 0, web page authors don't always use it. There are four possible values for mWriteState, and this assertion covers three of them; we fired for the fourth. ntdll.dll!7c901230() [Frames below may be incorrect and/or missing, no symbols loaded for ntdll.dll] > xpcom_core.dll!Break(const char * aMsg=0x0012e848) Line 471 C++ xpcom_core.dll!NS_DebugBreak_P(unsigned int aSeverity=1, const char * aStr=0x01e248c0, const char * aExpr=0x01e24860, const char * aFile=0x01e24810, int aLine=1072) Line 350 + 0xc bytes C++ gklayout.dll!nsHTMLDocument::EndLoad() Line 1072 + 0x40 bytes C++ gklayout.dll!HTMLContentSink::DidBuildModel() Line 2181 C++ gkparser.dll!CNavDTD::DidBuildModel(unsigned int anErrorCode=2152596471, int aNotifySink=1, nsIParser * aParser=0x04e00488, nsIContentSink * aSink=0x04e5eb74) Line 458 C++ gkparser.dll!nsParser::DidBuildModel(unsigned int anErrorCode=2152596471) Line 948 + 0x35 bytes C++ gkparser.dll!nsParser::Terminate() Line 1069 + 0xc bytes C++ gklayout.dll!nsDocument::StopDocumentLoad() Line 1184 C++ gklayout.dll!DocumentViewerImpl::Stop() Line 1634 C++ docshell.dll!nsDocShell::Stop(unsigned int aStopFlags=3) Line 3297 C++ docshell.dll!nsDocShell::Stop(unsigned int aStopFlags=3) Line 3318 C++ docshell.dll!nsDocShell::Destroy() Line 3584 C++ appshell.dll!nsXULWindow::Destroy() Line 507 C++ appshell.dll!nsWebShellWindow::Destroy() Line 834 + 0x9 bytes C++ appshell.dll!nsWebShellWindow::HandleEvent(nsGUIEvent * aEvent=0x0012f0ac) Line 393 C++ gkwidget.dll!nsWindow::DispatchEvent(nsGUIEvent * event=0x0012f0ac, nsEventStatus & aStatus=nsEventStatus_eIgnore) Line 1102 + 0xc bytes C++ gkwidget.dll!nsWindow::DispatchWindowEvent(nsGUIEvent * event=0x0012f0ac) Line 1123 C++ gkwidget.dll!nsWindow::DispatchStandardEvent(unsigned int aMsg=101) Line 1142 + 0x11 bytes C++ gkwidget.dll!nsWindow::ProcessMessage(unsigned int msg=16, unsigned int wParam=0, long lParam=0, long * aRetValue=0x0012f498) Line 4226 C++ gkwidget.dll!nsWindow::WindowProc(HWND__ * hWnd=0x001b04b0, unsigned int msg=16, unsigned int wParam=0, long lParam=0) Line 1291 + 0x1d bytes C++ user32.dll!77d48734() user32.dll!77d48816() xpcom_core.dll!nsReadingIterator<char>::advance(int n=0) Line 174 + 0x18 bytes C++ user32.dll!77d4b4c0() user32.dll!77d4b50c() ntdll.dll!7c90eae3() user32.dll!77d494be() user32.dll!77d4b42d() user32.dll!77d4baa4() user32.dll!77d4b96b() user32.dll!77d4b3f9() uxtheme.dll!5ad73c20() uxtheme.dll!5ad8e300() uxtheme.dll!5ad71ac7() uxtheme.dll!5ad71b3d() uxtheme.dll!5ad8e2d5() user32.dll!77d4bb15() nspr4.dll!_MD_CURRENT_THREAD() Line 296 + 0xc bytes C gkwidget.dll!nsWindow::DefaultWindowProc(HWND__ * hWnd=0x001b04b0, unsigned int msg=274, unsigned int wParam=61536, long lParam=1442394) Line 1312 C++ user32.dll!77d48734() user32.dll!77d48816() gkwidget.dll!nsBaseWidget::QueryInterface(const nsID & aIID={...}, void * * aInstancePtr=0x001b04b0) Line 64 + 0x84 bytes C++ user32.dll!77d4c63f() user32.dll!77d4c665() gkwidget.dll!nsWindow::WindowProc(HWND__ * hWnd=0x0646d3d4, unsigned int msg=1243400, unsigned int wParam=38545384, long lParam=0) Line 1298 + 0x1f bytes C++ nspr4.dll!PR_GetCurrentThread() Line 175 C gkwidget.dll!nsWindow::`vftable'() + 0x23 bytes C++ gkwidget.dll!02469aaf() 4d890cec()
Except that we should only get into EndLoad when we're in that particular state, and the HTML document needs to do more work to make sure we're in it. *** This bug has been marked as a duplicate of 332896 ***
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → DUPLICATE
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.