Closed Bug 581869 Opened 14 years ago Closed 14 years ago

Segmentation Fault when starting firefox

Categories

(Firefox :: General, defect)

x86
Linux
defect
Not set
critical

Tracking

()

RESOLVED INVALID

People

(Reporter: richardbiddle, Unassigned)

Details

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US) AppleWebKit/533.4 (KHTML, like Gecko) Chrome/5.0.375.70 Safari/533.4
Build Identifier: Ubuntu 3.6.6+nobinonly-0ubuntu0.10.04.1

Seg Fault on starting.

Program received signal SIGSEGV, Segmentation fault.
0xb703a250 in NewOrRecycledNode (tc=0xbfffe638) at jsparse.cpp:468
468	jsparse.cpp: No such file or directory.
	in jsparse.cpp


Reproducible: Always

Steps to Reproduce:
1. Browser randomly quit while changing to a new tab.
2. Now cannot start. Seg Fault



(gdb) bt
#0  0xb703a250 in NewOrRecycledNode (tc=0xbfffe638) at jsparse.cpp:468
#1  0xb7046652 in NewParseNode (cx=0xb2fa0800, fun=0xb3026ea8, principals=0x0, 
    chars=0xb7e23084, length=33, 
    filename=0xb7e22efe "javascript:return new XPCNativeWrapper(arg);", 
    lineno=1) at jsparse.cpp:555
#2  JSCompiler::compileFunctionBody (cx=0xb2fa0800, fun=0xb3026ea8, 
    principals=0x0, chars=0xb7e23084, length=33, 
    filename=0xb7e22efe "javascript:return new XPCNativeWrapper(arg);", 
    lineno=1) at jsparse.cpp:1485
#3  0xb6fad545 in JS_CompileUCFunctionForPrincipals (cx=0xb2fa0800, 
    obj=0xb31ea0e0, principals=0x0, name=0xb7e22f2b "_XPCNativeWrapperCtor", 
    nargs=1, argnames=0xbfffe9f8, chars=0xb7e23084, length=33, 
    filename=0xb7e22efe "javascript:return new XPCNativeWrapper(arg);", 
    lineno=1) at jsapi.cpp:4862
#4  0xb6fad63d in JS_CompileUCFunction (cx=0xb2fa0800, obj=0xb31ea0e0, 
    name=0xb7e22f2b "_XPCNativeWrapperCtor", nargs=1, argnames=0xbfffe9f8, 
    chars=0xb7e23084, length=33, 
    filename=0xb7e22efe "javascript:return new XPCNativeWrapper(arg);", 
    lineno=1) at jsapi.cpp:4819
#5  0xb7706322 in nsJSContext::FindXPCNativeWrapperClass (this=0xb2505d00, 
    aHolder=0xb2547c10) at nsJSEnvironment.cpp:3041
#6  0xb770721a in nsJSContext::InitContext (this=0xb2505d00, 
    aGlobalObject=0xb5c53ff0) at nsJSEnvironment.cpp:2600
#7  0xb7718640 in nsGlobalWindow::SetScriptContext (this=0xb5c53fc0, 
    lang_id=2, aScriptContext=0xb2505d00) at nsGlobalWindow.cpp:1207
#8  0xb771fba1 in nsGlobalWindow::EnsureScriptEnvironment (this=0xb5c53fc0, 
    aLangID=2) at nsGlobalWindow.cpp:1259
#9  0xb792438d in nsDocShell::EnsureScriptEnvironment (this=0xb4bb5950)
    at nsDocShell.cpp:9920
#10 0xb7929cdc in nsDocShell::GetInterface (this=0xb4bb5950, aIID=..., 
    aSink=0xbfffec0c) at nsDocShell.cpp:851
#11 0xb7bf7b15 in nsGetInterface::operator() (this=0xbfffec38, 
    aIID=<value optimized out>, aInstancePtr=0xbfffec0c)
    at nsIInterfaceRequestorUtils.cpp:52
#12 0xb7bf664f in nsCOMPtr_base::assign_from_helper (this=0xbfffec48, 
    helper=..., iid=...) at nsCOMPtr.cpp:150
#13 0xb797e3d2 in nsCOMPtr (this=0xb2fd2240, aWindow=0xbfffec94, 
    aJSContext=0xbfffec90) at ../../../dist/include/nsCOMPtr.h:621
#14 nsAppShellService::GetHiddenWindowAndJSContext (this=0xb2fd2240, 
    aWindow=0xbfffec94, aJSContext=0xbfffec90) at nsAppShellService.cpp:430
#15 0xb797e8de in nsAppShellService::SetXPConnectSafeContext (this=0xb2fd2240)
    at nsAppShellService.cpp:122
#16 0xb797ea05 in nsAppShellService::CreateHiddenWindow (this=0xb2fd2240, 
    aAppShell=0xb4b311f0) at nsAppShellService.cpp:199
#17 0xb798e034 in nsAppStartup::CreateHiddenWindow (this=0xb4bfae50)
    at nsAppStartup.cpp:152
#18 0xb72d5d70 in XRE_main (argc=1, argv=0xbffff294, aAppData=0xb5c18380)
    at nsAppRunner.cpp:3373
#19 0x001119e3 in main (argc=1, argv=0xbffff294) at nsBrowserApp.cpp:158
(gdb)
Via Synaptic Package Manager, I did a re-installation of just the firefox package and now it is working ok again without the segfault. (I did not download new package, just reinstalled existing cached package download)
Next day, and it happened again.. but seems to be segfaulting in a different location now.

Starting program: /usr/lib/firefox-3.6.6/firefox-bin 
[Thread debugging using libthread_db enabled]
[New Thread 0xb5490b70 (LWP 13900)]
[New Thread 0xb4affb70 (LWP 13901)]
[New Thread 0xb42feb70 (LWP 13902)]
[New Thread 0xb3afdb70 (LWP 13903)]
[New Thread 0xb2effb70 (LWP 13904)]
[New Thread 0xb24ffb70 (LWP 13905)]
[Thread 0xb24ffb70 (LWP 13905) exited]
[New Thread 0xb24ffb70 (LWP 13906)]

Program received signal SIGSEGV, Segmentation fault.
0xb70c8c16 in nanojit::Assembler::asm_exit (this=0xb4bdc8de, guard=0xb31dc928)
    at ./nanojit/Assembler.cpp:560
560	./nanojit/Assembler.cpp: No such file or directory.
	in ./nanojit/Assembler.cpp
(gdb) bt
#0  0xb70c8c16 in nanojit::Assembler::asm_exit (this=0xb4bdc8de, 
    guard=0xb31dc928) at ./nanojit/Assembler.cpp:560
#1  0xb70cad77 in nanojit::Assembler::gen (this=0xb4bdc844, reader=0xbfffe380)
    at ./nanojit/Assembler.cpp:1277
#2  0xb70cb21a in nanojit::Assembler::assemble (this=0xb4bdc844, 
    frag=0xb4bdcf54) at ./nanojit/Assembler.cpp:723
#3  0xb70cd2dc in nanojit::compile (assm=0xb4bdc844, frag=0xb4bdcf54)
    at ./nanojit/LIR.cpp:1969
#4  0xb70a4f5d in TraceRecorder::compile (this=0xb5cb4d90, tm=0x0)
    at jstracer.cpp:4212
#5  0xb70a76ed in TraceRecorder::closeLoop (this=0xb5cb4d90, slotMap=..., 
    exit=0xb1216114, consensus=@0xbfffe52c) at jstracer.cpp:4599
#6  0xb70ae762 in TraceRecorder::closeLoop (this=0xb5cb4d90, 
    consensus=@0xbfffe52c) at jstracer.cpp:4502
#7  0xb70aead6 in TraceRecorder::checkTraceEnd (this=0xb5cb4d90, 
    pc=0xb1223685 "\b\377\207V") at jstracer.cpp:5039
#8  0xb70af714 in TraceRecorder::relational (this=0xb5cb4d90, 
    op=<value optimized out>, tryBranchAfterCond=<value optimized out>)
    at jstracer.cpp:8624
#9  0xb70bbfad in TraceRecorder::monitorRecording (cx=0xb25b7c00, 
    tr=0xb5cb4d90, op=JSOP_LT) at jsopcode.tbl:139
#10 0xb7001746 in js_Interpret (cx=0xb25b7c00) at jsops.cpp:79
#11 0xb7007f11 in js_Execute (cx=0xb25b7c00, chain=0xb25f5ac0, 
---Type <return> to continue, or q <return> to quit---
    script=0xb147ad00, down=0x0, flags=0, result=0xbfffe944)
    at jsinterp.cpp:1601
#12 0xb6fad04a in JS_ExecuteScript (cx=0xb25b7c00, obj=0xb25f5ac0, 
    script=0xb147ad00, rval=0xbfffe944) at jsapi.cpp:4962
#13 0xb77083d0 in nsJSContext::ExecuteScript (this=0xb25f4ec0, 
    aScriptObject=0xb14a1f40, aScopeObject=0xb25f5ac0, aRetValue=0x0, 
    aIsUndefined=0x0) at nsJSEnvironment.cpp:1902
#14 0xb76ec8a6 in nsXULDocument::ExecuteScript (this=0xb1bf1c00, 
    aContext=0xb25f4ec0, aScriptObject=0xb14a1f40) at nsXULDocument.cpp:3669
#15 0xb76ec936 in nsXULDocument::ExecuteScript (this=0xb1bf1c00, 
    aScript=0xb14a6670) at nsXULDocument.cpp:3692
#16 0xb76f4cb3 in nsXULDocument::LoadScript (this=0xb1bf1c00, 
    aScriptProto=0xb14a6670, aBlock=0xbfffeab4) at nsXULDocument.cpp:3404
#17 0xb76f5243 in nsXULDocument::ResumeWalk (this=0xb1bf1c00)
    at nsXULDocument.cpp:3037
#18 0xb76ec1c9 in nsXULDocument::CachedChromeStreamListener::OnStopRequest (
    this=0xb150d390, request=0xb25c7320, aContext=0x0, aStatus=2153578529)
    at nsXULDocument.cpp:4560
#19 0xb793704a in nsDocumentOpenInfo::OnStopRequest (this=0xb1b472e0, 
    request=0xb25c7320, aCtxt=0x0, aStatus=2153578529) at nsURILoader.cpp:323
#20 0xb73ef846 in nsJARChannel::OnStopRequest (this=0xb25c7320, 
    req=0xb1b4f6a0, ctx=0x0, status=2153578529) at nsJARChannel.cpp:880
#21 0xb7352082 in nsInputStreamPump::OnStateStop (this=0xb1b4f6a0)
---Type <return> to continue, or q <return> to quit---
    at nsInputStreamPump.cpp:576
#22 0xb735233f in nsInputStreamPump::OnInputStreamReady (this=0xb1b4f6a0, 
    stream=0xb1b2f3e8) at nsInputStreamPump.cpp:401
#23 0xb7c178d3 in nsInputStreamReadyEvent::Run (this=0xb25f64e0)
    at nsStreamUtils.cpp:112
#24 0xb7c2c8d8 in nsThread::ProcessNextEvent (this=0xb5cdf8d0, mayWait=0, 
    result=0xbfffec2c) at nsThread.cpp:527
#25 0xb7bfb133 in NS_ProcessNextEvent_P (thread=0x0, mayWait=0)
    at nsThreadUtils.cpp:250
#26 0xb7b71a5d in mozilla::ipc::MessagePump::Run (this=0xb5cc5700, 
    aDelegate=0xb5c268a0) at MessagePump.cpp:118
#27 0xb7bc92aa in MessageLoop::RunInternal (this=0xb5c268a0)
    at ./src/base/message_loop.cc:216
#28 0xb7bc92ce in MessageLoop::RunHandler (this=0xb5c268a0)
    at ./src/base/message_loop.cc:199
#29 0xb7bc9345 in MessageLoop::Run (this=0xb5c268a0)
    at ./src/base/message_loop.cc:173
#30 0xb7acc7ec in nsBaseAppShell::Run (this=0xb4b301f0)
    at nsBaseAppShell.cpp:174
#31 0xb798df78 in nsAppStartup::Run (this=0xb4bfaf70) at nsAppStartup.cpp:183
#32 0xb72d6246 in XRE_main (argc=1, argv=0xbffff284, aAppData=0xb5c18380)
    at nsAppRunner.cpp:3483
#33 0x001119e3 in main (argc=1, argv=0xbffff284) at nsBrowserApp.cpp:158
Fixed the issue again by reinstalling:
$ sudo dpkg -i /var/cache/apt/archives/firefox_3.6.6+nobinonly-0ubuntu0.10.04.1_i386.deb 
Preparing to replace firefox 3.6.6+nobinonly-0ubuntu0.10.04.1 (using .../firefox_3.6.6+nobinonly-0ubuntu0.10.04.1_i386.deb) ...
Unpacking replacement firefox ...
Setting up firefox (3.6.6+nobinonly-0ubuntu0.10.04.1) ...
Please restart all running instances of firefox, or you will experience problems.

And now starts without a segfault.
I think this may be due to a memory issue on my computer.
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.