Closed Bug 1742590 Opened 3 years ago Closed 3 years ago

If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog / @ nsMsgAttachmentData::~nsMsgAttachmentData occurs, @ MimeInlineTextHTMLParsed_parse_line, @ MimeInlineTextHTMLSanitized_parse_line

Categories

(Thunderbird :: General, defect)

Thunderbird 95
x86_64
Windows 10
defect

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: thee.chicago.wolf, Unassigned)

References

()

Details

After the fixes for bug 1734847 landed in 95.0b4, running a Repair Folder operation on Inboxes and then attempting to shut down TB will cause what appears to be a huge memory leak / spike and subsequent hang that leads to a crash: https://crash-stats.thunderbird.net/report/bp-00f65de1-1f72-4ff9-a3c2-412621211123

Summary: If running a Repair FOlder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog occurs → If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog occurs

Assuming you have a slew of munged emails that's lead to a damaged Inbox, STR:

  1. Using 95.0b4, start a Repair Folder operation on an Inbox (in my case, a GMail Inbox with 48k+ emails)
  2. Let TB begin doing it's repair and within 10-15, try to close TB via File > Exit or by clicking the close [X] button at top right.
  3. Task manager should slowly creep up in mem usage and TB will be in an out of a state of Not Responding and eventually crash

Was able to repro again just now: https://crash-stats.thunderbird.net/report/bp-bb7b0680-a326-4855-8d59-419a01211123

It's not (was not) the actual mails that were damaged, only the values in the index (.msf) were wrong.

(In reply to Magnus Melin [:mkmelin] from comment #2)

It's not (was not) the actual mails that were damaged, only the values in the index (.msf) were wrong.

So if the mails are already mangled, that's permanent because what eventually comes down to the client (in my case via IMAP) is clean but gets mangled locally will eventually get sync'd back to the IMAP server?

So I wanted to supplement my STR in comment 1 with something that might help repro this. I have now noticed that when a Folder Repair operation is happening and one is able to observe the "Downloading message X of Y in <mailbox name>" in the Status Bar, if you happen to click on a newly arrived email while the repair operation is happening, progress in the Status Bar will disappear but Task Manager will still show TB utilizing CPU.

Status Bar progress never comes back but it does increase the ability to cause the mem usage to go up and eventually crash TB. The only way to recover Status Bar progress being displayed is to File > Exit TB or End Task on the process and restart TB.

Locally mangled copy of an imap mail (if that would ever happen) won't ever get synced back to the server AFAIK. The mails are just cache basically.

(In reply to Magnus Melin [:mkmelin] from comment #5)

Locally mangled copy of an imap mail (if that would ever happen) won't ever get synced back to the server AFAIK. The mails are just cache basically.

Thanks Magnus.

I think there's a relationship between this one and bug 1740486.

Summary: If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog occurs → If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog / @ nsMsgAttachmentData::~nsMsgAttachmentData occurs

95.0b5 seems to be having a new crash on shutdown (@ nsMsgAttachmentData::~nsMsgAttachmentData) as opposed to 95.0b4.

Tons more crashes:

https://crash-stats.thunderbird.net/report/bp-3c59b01a-73e0-40cc-84e3-84f821211203
https://crash-stats.thunderbird.net/report/bp-9c3c2ba0-b1bc-49cc-b4f4-04d491211202
https://crash-stats.thunderbird.net/report/bp-686ddf04-cf70-4afe-be60-667181211202
https://crash-stats.thunderbird.net/report/bp-2b340fd8-7a30-4349-8d19-7f1ac1211202
https://crash-stats.thunderbird.net/report/bp-e2827d65-f3ce-4057-a6c8-e50831211202
https://crash-stats.thunderbird.net/report/bp-80febe58-46c0-4d45-a50c-4bc9e1211202
https://crash-stats.thunderbird.net/report/bp-32d8118c-4d09-40df-8b3b-13b461211202
https://crash-stats.thunderbird.net/report/bp-aeede7ac-4aa7-495a-b14f-94df61211201
https://crash-stats.thunderbird.net/report/bp-96e5b05b-aad2-48e7-98ac-c26781211201
https://crash-stats.thunderbird.net/report/bp-6993f892-19da-4fa1-afe1-343191211201
https://crash-stats.thunderbird.net/report/bp-e7b9076f-c768-4174-a096-da5cd1211201
https://crash-stats.thunderbird.net/report/bp-59edd26c-d014-4b45-818a-b95421211201
https://crash-stats.thunderbird.net/report/bp-58e26c71-df93-4afa-88d5-14e261211201
https://crash-stats.thunderbird.net/report/bp-6fb1ca8c-81d3-4eed-81ec-5b7441211201
https://crash-stats.thunderbird.net/report/bp-384016e0-ce16-4b75-a5fb-84ff81211130
https://crash-stats.thunderbird.net/report/bp-eb66e1f9-ffbf-4da8-bcae-74dee1211130
https://crash-stats.thunderbird.net/report/bp-43824e58-95ee-46bf-ae92-5694c1211130
https://crash-stats.thunderbird.net/report/bp-fe7718ee-f5e0-4326-9791-2cc7b1211130
https://crash-stats.thunderbird.net/report/bp-03cac325-8577-41d3-97ed-4ffe81211130
https://crash-stats.thunderbird.net/report/bp-3e9d3ae2-3220-4a39-be9b-a23591211130
https://crash-stats.thunderbird.net/report/bp-4721a06e-b850-4858-b1c5-ac2c31211130
https://crash-stats.thunderbird.net/report/bp-a085edf7-c844-4709-923c-5f6b51211130

And in case you're wondering, it still happens in Safe mode as well.

Summary: If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog / @ nsMsgAttachmentData::~nsMsgAttachmentData occurs → If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog / @ nsMsgAttachmentData::~nsMsgAttachmentData occurs, [@ MimeInlineTextHTMLParsed_parse_line ]
Summary: If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog / @ nsMsgAttachmentData::~nsMsgAttachmentData occurs, [@ MimeInlineTextHTMLParsed_parse_line ] → If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog / @ nsMsgAttachmentData::~nsMsgAttachmentData occurs, @ MimeInlineTextHTMLParsed_parse_line
Depends on: 1740486

Crash in 96.0b1 shows a slight change in "patched_BaseThreadInitThunk" line error location: https://crash-stats.thunderbird.net/report/bp-2190f8e7-1f08-44a2-a4a8-a474c1211207

Crash info at the above URL (https://crash-stats.thunderbird.net/report/bp-43da773c-ed95-4274-a828-cac7c1211212) lines up with my crashes too.

Signature of crash on exit seems to have changed with 97.0b1. I am now seeing [@ MimeInlineTextHTMLSanitized_parse_line] > https://crash-stats.thunderbird.net/report/bp-e83aeb72-0fb0-45c4-b7ab-9e8c01220112

Also, in just the couple days of using 97.0b1, it seems to be crashing less on exit.Maybe just a fluke but 96.0 betas and early crashed on nearly every exit of the app.

Summary: If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog / @ nsMsgAttachmentData::~nsMsgAttachmentData occurs, @ MimeInlineTextHTMLParsed_parse_line → If running a Repair Folder operation and attempting to shut down, crash @ mozilla::`anonymous namespace'::RunWatchdog / @ nsMsgAttachmentData::~nsMsgAttachmentData occurs, @ MimeInlineTextHTMLParsed_parse_line, @ MimeInlineTextHTMLSanitized_parse_line

I went the nuclear route today and backed up my current profile, removed TB and all associated profile folders and started from scratch. Since this is a brand spanking new profile, I thought I wasn't going to be seeing and crashes on exit but I got a new crash signature ([@ static XPCWrappedNative::CallMethod ]): https://crash-stats.thunderbird.net/report/bp-0e43d45b-4e42-4093-9730-843d61220221

If you want me to open a new bug, let me know.

This new crash looks like it might be similar to bug 1754369 or bug 1753968 apparently.

Yes that is bug 1754369.

Arthur: how is this in current daily (or beta)?
It seems to work fine for me.

(In reply to Magnus Melin [:mkmelin] from comment #19)

Arthur: how is this in current daily (or beta)?
It seems to work fine for me.

It works fine...after having completely re-done my TB profile from scratch. I would guess if I had not, I'd still be stuck in the mire. What I did in comment 18 fixed this so closing as WFM.

This issue may come back once people upgrade from 91 ESR to 102 ESR though so keep your eyes peeled. No one's yet to figure out what change between 91 and 100b is causing this, IMHO, profile corruption.

Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.