Closed Bug 755767 Opened 8 years ago Closed 8 years ago

Shut down indexedDB on profile-before-change

Categories

(Core :: Storage: IndexedDB, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla16

People

(Reporter: bent.mozilla, Assigned: khuey)

References

Details

Attachments

(1 file)

We shut everything down at xpcom-shutdown currently and that's too late. We rely on the profile directory (and we want to support fast _exit()) so we should use profile-before-change.
Assignee: nobody → khuey
Blocks: 726378
Attached patch PatchSplinter Review
I wrote this last week.  It appears to just work.
Attachment #629935 - Flags: review?(bent.mozilla)
Comment on attachment 629935 [details] [diff] [review]
Patch

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

::: dom/indexedDB/IndexedDatabaseManager.cpp
@@ +238,5 @@
>      nsCOMPtr<nsIObserverService> obs = GetObserverService();
>      NS_ENSURE_TRUE(obs, nsnull);
>  
>      // We need this callback to know when to shut down all our threads.
> +    rv = obs->AddObserver(instance, "profile-before-change", false);

Nit: Let's use a #define
Attachment #629935 - Flags: review?(bent.mozilla) → review+
https://hg.mozilla.org/mozilla-central/rev/0099fbd7c5f3
Status: NEW → RESOLVED
Closed: 8 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
Target Milestone: --- → mozilla16
You need to log in before you can comment on or make changes to this bug.