Crash when saving JSON

RESOLVED FIXED in Firefox 55

Status

--
critical
RESOLVED FIXED
a year ago
2 months ago

People

(Reporter: Oriol, Assigned: Oriol)

Tracking

({crash})

unspecified
Firefox 55
crash

Firefox Tracking Flags

(firefox-esr52 unaffected, firefox53 unaffected, firefox54 unaffected, firefox55 fixed)

Details

(crash signature)

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

a year ago
# Variant 1

 1. Open Firefox in e10s mode
 2. Load data:application/json,[1,2,3]
 3. Click Save button (then you can cancel the dialog)
 4. Open a new tab
 5. Open a new window
 6. Load data:application/json,[1,2,3]
 7. Click Save button

Result:
 - The whole browser crashes
   https://crash-stats.mozilla.com/report/index/5568c8ab-597b-42c1-866a-9fba80170531

# Variant 2

Like variant 1, but skip step 4.

Result:
 - The tab in the old window crashes
   https://crash-stats.mozilla.com/report/index/4bba79eb-cf16-47ea-a5bb-b62700170531
 - Save dialog does not open
 - The browser console shows this error:
   NS_ERROR_FAILURE: saveBrowser failed asynchronously in startPersistence

# Variant 3

Like variant 1 or 2, but without e10s.

Result:
 - No crash :)
 - Save dialog does not open
 - The browser console shows this error:
   NS_ERROR_FAILURE: saveBrowser failed asynchronously in startPersistence




I guess I shouldn't have tried to reuse the same window in bug 1327784, but a crash is surprising.
(Assignee)

Comment 1

a year ago
Created attachment 8873190 [details] [diff] [review]
json-save-fixcrash.patch

Small fix, seems to fix the problem.

I attempted to load contentAreaUtils in converter-child.js and save there.
I managed to get the save dialog, but then it didn't save.
So meanwhile, this patch is better.
Assignee: nobody → oriol-bugzilla
Status: NEW → ASSIGNED
Attachment #8873190 - Flags: review?(odvarko)
(Assignee)

Comment 2

a year ago
The underlying issue behind the crash is bug 1369246, but the JSON Viewer needs to be fixed in order to be able to save in the cases described in comment 0.
(Assignee)

Comment 3

a year ago
Created attachment 8873407 [details] [diff] [review]
json-save-fixcrash-v2.patch

While I'm at it, removing some unused code leftover after bug 1327784.
Attachment #8873190 - Attachment is obsolete: true
Attachment #8873190 - Flags: review?(odvarko)
Attachment #8873407 - Flags: review?(odvarko)
Comment on attachment 8873407 [details] [diff] [review]
json-save-fixcrash-v2.patch

Review of attachment 8873407 [details] [diff] [review]:
-----------------------------------------------------------------

Fixes the problem, thanks!

R+

Honza
Attachment #8873407 - Flags: review?(odvarko) → review+
(Assignee)

Updated

a year ago
Keywords: checkin-needed

Comment 5

a year ago
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/5f83e3e0c2ed
Do not reuse the chrome window when saving in JSON Viewer. r=Honza
Keywords: checkin-needed

Comment 6

a year ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/5f83e3e0c2ed
Status: ASSIGNED → RESOLVED
Last Resolved: a year ago
status-firefox55: affected → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 55
status-firefox-esr52: --- → unaffected

Updated

2 months ago
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.