Closed Bug 1249590 Opened 4 years ago Closed 4 years ago

Make AsyncShutdown more resilient to exceptions

Categories

(Toolkit :: Async Tooling, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla47
Tracking Status
firefox47 --- fixed

People

(Reporter: Yoric, Assigned: Yoric)

References

Details

Attachments

(1 file)

No description provided.
While investigating bug 1248489, we discovered that some code paths in
AsyncShutdown could possibly be sensitive to exceptions being thrown
in unexpected places. This patch attempts to make AsyncShutdown more
robust to such exceptions.

Review commit: https://reviewboard.mozilla.org/r/35631/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/35631/
Attachment #8721292 - Flags: review?(nfroyd)
Comment on attachment 8721292 [details]
MozReview Request: Bug 1249590 - Bullet-proofing AsyncShutdown wrt exceptions;r?froydnj

https://reviewboard.mozilla.org/r/35631/#review32301

This patch is basically what I expected it to be from the description, which is good. :)

::: toolkit/components/asyncshutdown/AsyncShutdown.jsm:541
(Diff revision 1)
> +      debug("Error in nsIObserve.observe");

Nit: maybe something like "Error waiting for the barrier" or somesuch?

::: toolkit/components/asyncshutdown/AsyncShutdown.jsm:693
(Diff revision 1)
>          throw new Error(`Phase "${ this._name } is finished, it is too late to register completion condition "${ name }"`);

Nit: The first ${ this._name } is missing a closing double-quote.
Attachment #8721292 - Flags: review?(nfroyd) → review+
Assignee: nobody → dteller
Comment on attachment 8721292 [details]
MozReview Request: Bug 1249590 - Bullet-proofing AsyncShutdown wrt exceptions;r?froydnj

Review request updated; see interdiff: https://reviewboard.mozilla.org/r/35631/diff/1-2/
https://hg.mozilla.org/mozilla-central/rev/3a336fe9269c
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla47
Depends on: 1252452
You need to log in before you can comment on or make changes to this bug.