Bug 21476

Summary: REGRESSION (r37427): Infinite recursion loading about:blank
Product: WebKit Reporter: Timothy Hatcher <timothy>
Component: JavaScriptCoreAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: darin, mjs, zwarich
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   

Description Timothy Hatcher 2008-10-08 10:43:18 PDT
Infinite recursion loading about:blank after r37427.

http://trac.webkit.org/changeset/37427

#0	0x00c2c0de in JSC::ExecState::scopeChain at ExecState.h:43
#1	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#2	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#3	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#4	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#5	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#6	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#7	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#8	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#9	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#10	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#11	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#12	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#13	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#14	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#15	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#16	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#17	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#18	0x00c2c0f2 in JSC::ExecState::scopeChain at ExecState.h:43
#19	0x00c2c13d in JSC::ExecState::globalData at ExecState.h:69
#20	0x00c2c1fb in JSC::ExecState::heap at ExecState.h:86
#21	0x00bd8329 in JSC::JSCell::operator new at JSCell.cpp:82
#22	0x00c22c2a in JSC::JSGlobalObject::reset at JSGlobalObject.cpp:203
#23	0x00c25aba in JSC::JSGlobalObject::init at JSGlobalObject.cpp:147
#24	0x039e9207 in JSC::JSGlobalObject::JSGlobalObject at JSGlobalObject.h:154
#25	0x039e3516 in WebCore::JSDOMWindowBase::JSDOMWindowBase at JSDOMWindowBase.cpp:175
#26	0x03615f83 in WebCore::JSDOMWindow::JSDOMWindow at JSDOMWindow.cpp:491
#27	0x03a71fe3 in WebCore::JSDOMWindowShell::setWindow at JSDOMWindowShell.cpp:61
#28	0x03a720a3 in WebCore::JSDOMWindowShell::JSDOMWindowShell at JSDOMWindowShell.cpp:50
#29	0x0397cf77 in WebCore::ScriptController::initScript at ScriptController.cpp:177
#30	0x03aeb6f0 in WebCore::ScriptController::initScriptIfNeeded at ScriptController.h:133
#31	0x0397d312 in WebCore::ScriptController::evaluate at ScriptController.cpp:96
#32	0x0350fc2d in WebCore::FrameLoader::executeScript at FrameLoader.cpp:793
#33	0x035a26fa in WebCore::HTMLTokenizer::scriptExecution at HTMLTokenizer.cpp:563
#34	0x035a2b60 in WebCore::HTMLTokenizer::notifyFinished at HTMLTokenizer.cpp:2012
#35	0x03354558 in WebCore::CachedScript::checkNotify at CachedScript.cpp:93
#36	0x033546b9 in WebCore::CachedScript::data at CachedScript.cpp:83
#37	0x039837e7 in WebCore::Loader::Host::didFinishLoading at loader.cpp:300
#38	0x03902683 in WebCore::SubresourceLoader::didFinishLoading at SubresourceLoader.cpp:194
#39	0x03829304 in WebCore::ResourceLoader::didFinishLoading at ResourceLoader.cpp:398
#40	0x038268e2 in -[WebCoreResourceHandleAsDelegate connectionDidFinishLoading:] at ResourceHandleMac.mm:530
#41	0x92b8e097 in -[NSURLConnection(NSURLConnectionReallyInternal) sendDidFinishLoading]
#42	0x92b8e003 in _NSURLConnectionDidFinishLoading
#43	0x948fa209 in sendDidFinishLoadingCallback
#44	0x948f7180 in _CFURLConnectionSendCallbacks
#45	0x948f6a25 in muxerSourcePerform
#46	0x9415c65f in CFRunLoopRunSpecific
#47	0x9415ccf8 in CFRunLoopRunInMode
#48	0x95946480 in RunCurrentEventLoopInMode
#49	0x959461d2 in ReceiveNextEventCommon
#50	0x9594610d in BlockUntilNextEventMatchingListInMode
#51	0x91dd93ed in _DPSNextEvent
#52	0x91dd8ca0 in -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:]
#53	0x001a56c1 in -[BrowserApplication nextEventMatchingMask:untilDate:inMode:dequeue:] at BrowserApplication.mm:239
#54	0x91dd1cdb in -[NSApplication run]
#55	0x91d9ef14 in NSApplicationMain
#56	0x00032921 in main at main.m:13
Comment 1 Darin Adler 2008-10-08 10:46:55 PDT
Aggh! This was working on my machine. I must have made a last minute change that broke it. I'm in a meeting. Can someone else fix this?
Comment 2 Darin Adler 2008-10-08 10:48:32 PDT
The fix is this:

- CodeBlock* codeBlock() const { return this[RegisterFile::CodeBlock].codeBlock(); } 
- ScopeChainNode* scopeChain() const { return this[RegisterFile::ScopeChain].scopeChain(); } 
+ CodeBlock* codeBlock() const { return this[RegisterFile::CodeBlock].Register::codeBlock(); } 
+ ScopeChainNode* scopeChain() const { return this[RegisterFile::ScopeChain].Register::scopeChain(); } 
Comment 3 Darin Adler 2008-10-08 10:49:47 PDT
Cameron, are you free to land the fix?

Tim, maybe you could?
Comment 4 Timothy Hatcher 2008-10-08 10:52:54 PDT
Darin, sorry I was too quick to roll this out before I saw your comments.

Rolled out in r37428.

I can roll it back in and test your fix.
Comment 5 Timothy Hatcher 2008-10-08 10:54:30 PDT
The release build also fails.

/Users/buildbot/Desktop/BuildData/WebKit-BuildSlave/trunk-mac-ppc-release/build/JavaScriptCore/VM/Machine.cpp:3349: warning: unused variable 'activation'

I will fix that too.
Comment 6 Darin Adler 2008-10-08 10:55:05 PDT
(In reply to comment #4)
> Darin, sorry I was too quick to roll this out before I saw your comments.
>
> Rolled out in r37428.
>
> I can roll it back in and test your fix.

If you have time to do this, it would be great. If not I'll get to this later (maybe much later).
Comment 7 Darin Adler 2008-10-08 10:56:43 PDT
(In reply to comment #5)
> The release build also fails.
> 
> /Users/buildbot/Desktop/BuildData/WebKit-BuildSlave/trunk-mac-ppc-release/build/JavaScriptCore/VM/Machine.cpp:3349:
> warning: unused variable 'activation'
> 
> I will fix that too.

Don't fix it by removing that variable!

I tried to check in a fix for that from home but it looks like my commit failed; it's a missing copyRegisters call.
Comment 8 Darin Adler 2008-10-08 10:57:08 PDT
Lets close this and reopen bug 21403.
Comment 9 Timothy Hatcher 2008-10-08 10:58:25 PDT
(In reply to comment #6)
> If you have time to do this, it would be great. If not I'll get to this later
> (maybe much later).

I will just leave it to you, I should be working on other things.
Comment 10 Timothy Hatcher 2008-10-08 10:58:54 PDT
(In reply to comment #8)
> Lets close this and reopen bug 21403.

OK. Done