Closed Bug 1684764 Opened 5 years ago Closed 9 months ago

startup Crash in [@ mozilla::detail::nsTStringRepr<T>::First | nsMsgComposeService::Handle] via nsCommandLine

Categories

(MailNews Core :: Composition, defect)

defect

Tracking

(thunderbird_esr140 fixed, thunderbird143 affected)

RESOLVED FIXED
144 Branch
Tracking Status
thunderbird_esr140 --- fixed
thunderbird143 --- affected

People

(Reporter: wsmwk, Assigned: mkmelin)

Details

(Keywords: crash, Whiteboard: [rare][startupcrash])

Crash Data

Attachments

(1 file)

Crash report: https://crash-stats.mozilla.org/report/index/93a350f8-2e4d-4733-98ff-f9fa90210103

MOZ_CRASH Reason: MOZ_RELEASE_ASSERT(this->mLength > 0) (|First()| called on an empty string)

Top 10 frames of crashing thread:

0 xul.dll mozilla::detail::nsTStringRepr<char16_t>::First const xpcom/string/nsTSubstring.cpp:943
1 xul.dll nsMsgComposeService::Handle comm/mailnews/compose/src/nsMsgComposeService.cpp:1375
2 xul.dll EnumRun toolkit/components/commandlines/nsCommandLine.cpp:490
3 xul.dll nsCommandLine::EnumerateHandlers toolkit/components/commandlines/nsCommandLine.cpp:445
4 xul.dll nsCommandLine::Run toolkit/components/commandlines/nsCommandLine.cpp:500
5 xul.dll XREMain::XRE_mainRun toolkit/xre/nsAppRunner.cpp:4593
6 xul.dll XREMain::XRE_main toolkit/xre/nsAppRunner.cpp:4812
7 xul.dll XRE_main toolkit/xre/nsAppRunner.cpp:4866
8 xul.dll mozilla::BootstrapImpl::XRE_main toolkit/xre/Bootstrap.cpp:45
9 thunderbird.exe NS_internal_main comm/mail/app/nsMailApp.cpp:324
Flags: needinfo?(mkmelin+mozilla)

Fixing the crash per se would be easy. But takes some figuring out what this code is really supposed to do or not.
Crashes at https://searchfox.org/comm-central/rev/d2d1e5d5d857bafbb63e341903ba899eaf38c574/mailnews/compose/src/nsMsgComposeService.cpp#1378

Assignee: nobody → benc
Component: General → Composition
Flags: needinfo?(mkmelin+mozilla)
Product: Thunderbird → MailNews Core

Crash rate dropped 80-90% in April. Perhaps with 78.9.1. Or some other change.

Severity: -- → S3
Whiteboard: [rare]
Severity: S3 → S4
Whiteboard: [rare] → [rare][startupcrash]
Version: unspecified → 60

bp-838b34fe-bb79-4f9d-a0d0-610990210822 91.0.1
0 xul.dll mozilla::detail::nsTStringRepr<char16_t>::First() const xpcom/string/nsTSubstring.cpp:968
1 xul.dll nsMsgComposeService::Handle(nsICommandLine*) comm/mailnews/compose/src/nsMsgComposeService.cpp:1386
2 xul.dll nsCommandLine::EnumerateHandlers(nsresult ()(nsICommandLineHandler, nsICommandLine*, void*), void*) toolkit/components/commandlines/nsCommandLine.cpp:466
3 xul.dll nsCommandLine::Run() toolkit/components/commandlines/nsCommandLine.cpp:521
4 xul.dll XREMain::XRE_mainRun() toolkit/xre/nsAppRunner.cpp:5151
5 xul.dll XREMain::XRE_main(int, char**, mozilla::BootstrapConfig const&) toolkit/xre/nsAppRunner.cpp:5434

Status: NEW → ASSIGNED

version 91 is still virtually zero.

version 78.14.0 example mozilla::detail::nsTStringRepr<T>::First | nsMsgComposeService::Handle bp-b60e43f3-ce76-4313-b021-623f80211109
0 xul.dll mozilla::detail::nsTStringRepr<char16_t>::First() const
1 xul.dll nsMsgComposeService::Handle(nsICommandLine*)
2 xul.dll EnumRun(nsICommandLineHandler*, nsICommandLine*, void*)
3 xul.dll nsCommandLine::EnumerateHandlers(nsresult ()(nsICommandLineHandler, nsICommandLine*, void*), void*)
4 xul.dll nsCommandLine::Run()
5 xul.dll WindowProc(HWND__, unsigned int, unsigned int, long)
6 user32.dll _InternalCallWinProc
7 user32.dll long __stdcall UserCallWinProcCheckWow(struct _ACTIVATION_CONTEXT
, void*, struct HWND__, enum _WM_VALUE, unsigned int, long, void, int)
8 user32.dll DispatchClientMessage
9 user32.dll _fnCOPYDATA
10 ntdll.dll KiUserCallbackDispatcher
11 ntdll.dll KiUserApcDispatcher
12 user32.dll PeekMessageW
13 msctf.dll virtual long stdcall CThreadInputMgr::PeekMessageW(struct tagMSG*, struct HWND, unsigned int, unsigned int, unsigned int, int)

Still rare in the last 6 months, with no version 128 crashes for linux, and the only two windows are from the same person who has bitdefender addon installed.

So closing this WFM

Assignee: benc → nobody
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → WORKSFORME

One of the top crashes now (though not many crashes)

Status: RESOLVED → REOPENED
Resolution: WORKSFORME → ---
Assignee: nobody → mkmelin+mozilla
OS: Windows 7 → All
Hardware: x86 → All
Target Milestone: --- → 144 Branch

Pushed by martin@humanoids.be:
https://hg.mozilla.org/comm-central/rev/93a6a10aed3d
Fix crash in [@ mozilla::detail::nsTStringRepr<T>::First | nsMsgComposeService::Handle] via nsCommandLine. r=edicharry

Status: REOPENED → RESOLVED
Closed: 1 year ago9 months ago
Resolution: --- → FIXED

Comment on attachment 9508168 [details]
Bug 1684764 - Fix crash in [@ mozilla::detail::nsTStringRepr<T>::First | nsMsgComposeService::Handle] via nsCommandLine. r=#thunderbird-back-end-reviewers

Uplift Approval Request

  • Please state case for uplift consideration and ensure bug severity is set: Crash fix
  • User impact if declined: May crash
  • Is this code covered by automated tests?: No
  • Has the fix been verified in Daily?: Yes
  • Has the fix been verified in Beta?: No
  • Needs manual test from QA?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Simple crash fix
  • Does the fix cause any migrations to be skipped?: No
  • String changes made/needed: none
Attachment #9508168 - Flags: approval-comm-esr140?
Attachment #9508168 - Flags: approval-comm-beta?

Comment on attachment 9508168 [details]
Bug 1684764 - Fix crash in [@ mozilla::detail::nsTStringRepr<T>::First | nsMsgComposeService::Handle] via nsCommandLine. r=#thunderbird-back-end-reviewers

[Triage Comment]
Approved for beta

Attachment #9508168 - Flags: approval-comm-beta? → approval-comm-beta+

Comment on attachment 9508168 [details]
Bug 1684764 - Fix crash in [@ mozilla::detail::nsTStringRepr<T>::First | nsMsgComposeService::Handle] via nsCommandLine. r=#thunderbird-back-end-reviewers

[Triage Comment]
This will be included in Monday's merge of central->beta

Attachment #9508168 - Flags: approval-comm-beta+ → approval-comm-beta-

Comment on attachment 9508168 [details]
Bug 1684764 - Fix crash in [@ mozilla::detail::nsTStringRepr<T>::First | nsMsgComposeService::Handle] via nsCommandLine. r=#thunderbird-back-end-reviewers

[Triage Comment]
Approved for esr140

Attachment #9508168 - Flags: approval-comm-esr140? → approval-comm-esr140+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: