crash in nsLDAPOperation::GetMessageListener @ nsXPCWrappedJS::AddRef

RESOLVED FIXED in Thunderbird 24.0


6 years ago
6 years ago


(Reporter: scoobidiver, Assigned: neil)


({crash, regression, topcrash})

24 Branch
Thunderbird 24.0
Windows 7
crash, regression, topcrash
Dependency tree / graph

Thunderbird Tracking Flags

(thunderbird23 unaffected, thunderbird24+ fixed)


(crash signature)


(1 attachment, 1 obsolete attachment)



6 years ago
It's a new signature in TB 24.0a1/20130612 and a regression from bug 770840.

Frame 	Module 	Signature 	Source
0 	xul.dll 	nsXPCWrappedJS::AddRef 	js/xpconnect/src/XPCWrappedJS.cpp:158
1 	xul.dll 	nsXPTCStubBase::AddRef 	xpcom/reflect/xptcall/src/xptcall.cpp:30
2 	xul.dll 	nsLDAPOperation::GetMessageListener 	ldap/xpcom/src/nsLDAPOperation.cpp:161
3 	xul.dll 	nsLDAPConnection::InvokeMessageCallback 	ldap/xpcom/src/nsLDAPConnection.cpp:449
4 	xul.dll 	nsLDAPConnectionRunnable::Run 	ldap/xpcom/src/nsLDAPConnection.cpp:735
5 	xul.dll 	nsThread::ProcessNextEvent 	xpcom/threads/nsThread.cpp:626
6 	xul.dll 	NS_ProcessNextEvent 	objdir-tb/mozilla/xpcom/build/nsThreadUtils.cpp:238
7 	xul.dll 	nsThread::ThreadFunc 	xpcom/threads/nsThread.cpp:264
8 	nspr4.dll 	_PR_NativeRunThread 	nsprpub/pr/src/threads/combined/pruthr.c:397
9 	nspr4.dll 	pr_root 	nsprpub/pr/src/md/windows/w95thred.c:90
10 	msvcr100.dll 	_callthreadstartex 	f:\dd\vctools\crt_bld\self_x86\crt\src\threadex.c:314
11 	msvcr100.dll 	_threadstartex 	f:\dd\vctools\crt_bld\self_x86\crt\src\threadex.c:292
12 	kernel32.dll 	BaseThreadInitThunk 	
13 	ntdll.dll 	__RtlUserThreadStart 	
14 	ntdll.dll 	_RtlUserThreadStart 	

More reports at:
This will require fixes in mailnews code to use nsMainThreadPtrHolder.

Comment 2

6 years ago
Like the same problem reported in bug 882125.

Comment 3

6 years ago
Perhaps instead of getting the listener on the LDAP thread and then dispatching a runnable to the main thread, we could just get the runnable to get the listener from the operation.

Comment 4

6 years ago and will need to use nsMainThreadPtrHandle instead, with nsLDAPOperation holding on to an nsMainThreadPtrHandle that contains an nsMainThreadPtrHolder. nsOnLDAPMessageRunnable will need to use an nsMainThreadPtrHandle as well.

Comment 5

6 years ago
Created attachment 761580 [details] [diff] [review]
Untested patch

Gets the listener from the operation on the main thread.
Attachment #761580 - Flags: review?(mbanner)

Comment 6

6 years ago
Created attachment 761619 [details] [diff] [review]
Variant patch

Using friendship to simplify the code slightly.


6 years ago
Summary: TB crash in nsXPCWrappedJS::AddRef → crash in nsLDAPOperation::GetMessageListener @ nsXPCWrappedJS::AddRef


6 years ago
Blocks: 773610
Duplicate of this bug: 882125
tracking-thunderbird24: --- → +

Comment 8

6 years ago
me bp-e14f7d34-6a01-49d3-93c6-339202130613
#3 crash for TB24
Keywords: topcrash

Comment 9

6 years ago
To inform the tracking-thunderbird24+ status ...
- #1 crash for TB24
- crash rate of TB24a1 is 5-10x the rate of TB23a2[]=23.0a2&v[]=24.0a1&v[]=22.0b1&v[]=&hang_type=any&os[]=Windows&os[]=Mac+OS+X&os[]=Linux&date_range_type=report&date_start=2013-06-14&date_end=2013-06-23&submit=Generate
- for those running TB24, it appears to be merely annoying and not a debilitating crash. Still, it would be preferable I think to land this before cutting TB24.0a2 so as to not annoy Earlybird users to the extent that they stop running earlybird
Flags: needinfo?(mbanner)
Comment on attachment 761619 [details] [diff] [review]
Variant patch

Review of attachment 761619 [details] [diff] [review]:

I think I like this one best. r=Standard8. Sorry for the delay.
Attachment #761619 - Flags: review+
Attachment #761580 - Attachment is obsolete: true
Attachment #761580 - Flags: review?(mbanner)
Flags: needinfo?(mbanner)

Comment 11

6 years ago
Pushed comm-central changeset 67e02a3c68e1.
Assignee: nobody → neil
Last Resolved: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 24.0
status-thunderbird24: affected → fixed
You need to log in before you can comment on or make changes to this bug.