Closed Bug 621386 Opened 9 years ago Closed 9 years ago

Crash [@ mozilla::ipc::RPCChannel::CxxStackFrame::CxxStackFrame] (from PContentParent::SendGeolocationUpdate)


(Core :: DOM: Geolocation, defect)

Not set





(Reporter: jdm, Assigned: jdm)



(Keywords: crash)

Crash Data


(1 file, 2 obsolete files)

ID: 249f438f-1c28-46e5-b949-3da632101224
Signature: mozilla::ipc::RPCChannel::CxxStackFrame::CxxStackFrame

UUID	249f438f-1c28-46e5-b949-3da632101224
Time 	2010-12-24 19:47:56.841552
Uptime	742
Install Age	200080 seconds (2.3 days) since version was first installed.
Product	Fennec
Version	4.0b3
Build ID	20101221205132
Branch	1.9
OS	Linux
OS Version	0.0.0 Linux #1 PREEMPT Sun Nov 7 23:24:32 CST 2010 armv7l
CPU	arm
CPU Info	
Crash Reason	SIGSEGV
Crash Address	0x0
User Comments	
App Notes 	motorola DROIDX
Processor Notes 	
EMCheckCompatibility	False

Frame 	Module 	Signature [Expand] 	Source
0 	mozilla::ipc::RPCChannel::CxxStackFrame::CxxStackFrame 	RPCChannel.h:222
1 	mozilla::ipc::RPCChannel::Send 	ipc/glue/RPCChannel.cpp:142
2 	mozilla::dom::PContentParent::SendGeolocationUpdate 	PContentParent.cpp:475
3 	mozilla::dom::ContentParent::HandleEvent 	dom/ipc/ContentParent.cpp:781
4 	nsGeolocationRequest::SendLocation 	nsCOMPtr.h:800
5 	RequestSendLocationEvent::Run 	nsAutoPtr.h:1098
6 	nsThread::ProcessNextEvent 	xpcom/threads/nsThread.cpp:626
7 	NS_InvokeByIndex_P 	xpcom/reflect/xptcall/src/md/unix/xptcinvoke_arm.cpp:199
8 	XPCWrappedNative::CallMethod 	js/src/xpconnect/src/xpcwrappednative.cpp:3064
9 	XPC_WN_CallMethod 	js/src/xpconnect/src/xpcwrappednativejsops.cpp:1588
10 	js::Interpret 	js/src/jsinterp.cpp:4750
11 	js::Invoke 	js/src/jsinterp.cpp:657
12 	js_fun_apply 	js/src/jsfun.cpp:2292
13 	js::Interpret 	js/src/jsinterp.cpp:4750
14 	js::Invoke 	js/src/jsinterp.cpp:657
15 	js_fun_call 	js/src/jsfun.cpp:2226
16 	js::Interpret 	js/src/jsinterp.cpp:4750
17 	js::Invoke 	js/src/jsinterp.cpp:657
18 	js::ExternalInvoke 	js/src/jsinterp.cpp:858
19 	JS_CallFunctionValue 	js/src/jsinterp.h:962
20 	nsXPCWrappedJSClass::CallMethod 	js/src/xpconnect/src/xpcwrappedjsclass.cpp:1694
21 	nsXPCWrappedJS::CallMethod 	js/src/xpconnect/src/xpcwrappedjs.cpp:589
22 	PrepareAndDispatch 	xpcom/reflect/xptcall/src/md/unix/xptcstubs_arm.cpp:134
24 	nsNavHistory::RunInBatchMode 	toolkit/components/places/src/nsNavHistory.cpp:4412
25 		@0x4e9bd48f 	
26 	nsNavBookmarks::RunInBatchMode 	toolkit/components/places/src/nsNavBookmarks.cpp:2979
27 	NS_InvokeByIndex_P 	xpcom/reflect/xptcall/src/md/unix/xptcinvoke_arm.cpp:199
28 	xptiInterfaceEntry::GetEntryForParam 	xpcom/reflect/xptinfo/src/xptiInterfaceInfo.cpp:328
30 	XPCWrappedNative::CallMethod 	js/src/xpconnect/src/xpcwrappednative.cpp:3064
31 	XPC_WN_CallMethod 	js/src/xpconnect/src/xpcwrappednativejsops.cpp:1588
32 	js::Interpret 	js/src/jsinterp.cpp:4750
33 	js::Invoke 	js/src/jsinterp.cpp:657
34 	js_fun_apply 	js/src/jsfun.cpp:2292
35 	js::Interpret 	js/src/jsinterp.cpp:4750
36 	js::Invoke 	js/src/jsinterp.cpp:657
37 	js_fun_call 	js/src/jsfun.cpp:2226
38 	js::Interpret 	js/src/jsinterp.cpp:4750
39 	js::Invoke 	js/src/jsinterp.cpp:657
40 	js_fun_call 	js/src/jsfun.cpp:2226
41 	js::Interpret 	js/src/jsinterp.cpp:4750
42 	js::Invoke 	js/src/jsinterp.cpp:657
43 	js_fun_call 	js/src/jsfun.cpp:2226
44 	js::Interpret 	js/src/jsinterp.cpp:4750
45 	js::Invoke 	js/src/jsinterp.cpp:657
46 	js_fun_call 	js/src/jsfun.cpp:2226
47 	js::Interpret 	js/src/jsinterp.cpp:4750
48 	js::Invoke 	js/src/jsinterp.cpp:657
49 	js_fun_call 	js/src/jsfun.cpp:2226
50 	js::Interpret 	js/src/jsinterp.cpp:4750
51 	js::Invoke 	js/src/jsinterp.cpp:657
52 	js::ExternalInvoke 	js/src/jsinterp.cpp:858
53 	JS_CallFunctionValue 	js/src/jsinterp.h:962
54 	nsXPCWrappedJSClass::CallMethod 	js/src/xpconnect/src/xpcwrappedjsclass.cpp:1694
55 	nsXPCWrappedJS::CallMethod 	js/src/xpconnect/src/xpcwrappedjs.cpp:589
56 	PrepareAndDispatch 	xpcom/reflect/xptcall/src/md/unix/xptcstubs_arm.cpp:134
58 	nsTimerImpl::Fire 	xpcom/threads/nsTimerImpl.cpp:429
Let's guard sending the update to the parent with a check for mIsAlive.
Actually this is a better way to fix this crash.  The observers and listeners aren't helpful after the process dies, so let's move all the cleanup into a common location and trigger it on ActorDestroy or xpcom-shutdown, whichever comes first.
Duplicate of this bug: 577398
Attachment #499770 - Attachment is obsolete: true
Comment on attachment 499772 [details] [diff] [review]
Clean up all ContentParent observers and listeners on actor destruction and xpcom-shutdown.

Would be nice to have a test for this...
Attachment #499772 - Flags: review?(benjamin)
Attachment #499772 - Flags: review+
Attachment #499772 - Flags: approval2.0+
Assignee: nobody → josh
A test would require killing a content process.  Do we have any easy way of doing that?
Keywords: checkin-needed
Backed out in, because it caused xpcshell orange.
This wasn't actually backed out; the above messages belong in bug 621386.
Comment 10 is a lie, and the author of comment 10 is accordingly a liar.  Don't believe anything that liar writes; he is a liar.  He is also easily confused.
heh, I was gonna say...
Attachment #499772 - Attachment is obsolete: true
xpcshell tests broke because xpcom-shutdown called Cleanup then Close, which causes ActorDestroy to be called which itself calls Cleanup, and we assert trying to remove the observers again.  Accordingly, we can move all of the cleanup code into ActorDestroy, because it will be called in the case of xpcom-shutdown as well as unexpected errors.
Attachment #508449 - Flags: review?(benjamin)
Attachment #508449 - Attachment description: Clean up all ContentParent observers and listeners on actor destruction and xpcom-shutdown. up all ContentParent observers and listeners on actor destruction and xpcom-shutdown. r+ → Clean up all ContentParent observers and listeners on actor destruction and xpcom-shutdown.
Attachment #508449 - Flags: review?(benjamin) → review+
I think carrying over the a+ from the earlier functionally-equivalent patch is appropriate, so I'm marking this checkin-needed.
Keywords: checkin-needed
Closed: 9 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b12
Depends on: 631442
Crash Signature: [@ mozilla::ipc::RPCChannel::CxxStackFrame::CxxStackFrame]
You need to log in before you can comment on or make changes to this bug.