ServiceWorkerManager could WARN in more failure cases

RESOLVED FIXED in Firefox 40

Status

()

Core
DOM: Workers
RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: bkelly, Assigned: bkelly)

Tracking

unspecified
mozilla40
Points:
---

Firefox Tracking Flags

(firefox40 fixed)

Details

Attachments

(1 attachment)

(Assignee)

Description

3 years ago
In this try build:

  https://treeherder.mozilla.org/logviewer.html#?job_id=6921689&repo=try

I get the unhelpful:

  WARNING: 'NS_FAILED(aStatus)', file /builds/slave/try-m64-d-00000000000000000000/build/src/dom/workers/ServiceWorkerManager.cpp, line 135

This just says that some error made it to ServiceWorkerManager::Done(), but no indication of where it came from or what it is.
(Assignee)

Comment 1

3 years ago
Created attachment 8597356 [details] [diff] [review]
Improve ServiceWorkerManager NS_WARNINGS on failure. r=nsm

I ran this locally and saw both nsPrintfCString() calls execute correctly.  Also, it does not seem too spammy in the few runs I tried.
Assignee: nobody → bkelly
Status: NEW → ASSIGNED
Attachment #8597356 - Flags: review?(nsm.nikhil)
Comment on attachment 8597356 [details] [diff] [review]
Improve ServiceWorkerManager NS_WARNINGS on failure. r=nsm

>diff --git a/dom/workers/ServiceWorkerManager.cpp b/dom/workers/ServiceWorkerManager.cpp
>+    NS_WARNING(nsPrintfCString("ServiceWorkerJob failed with error: %s\n",
>+               errorName.get()).get());

Nit: the second line here is mis-indented. It's an argument for the "nsPrintfCString(...)" call, so it should be indented to just after "nsPrintfCString(".

(If you like, you could address this with a trivial "DONTBUILD, whitespace-only" followup)
https://hg.mozilla.org/mozilla-central/rev/98b0e8e0c180
https://hg.mozilla.org/mozilla-central/rev/e6c0425d3c88
Status: ASSIGNED → RESOLVED
Last Resolved: 3 years ago
status-firefox40: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla40
You need to log in before you can comment on or make changes to this bug.