Closed Bug 776764 Opened 12 years ago Closed 12 years ago

Allow permissionDB parent directory to not be the default profile directory

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla17
blocking-basecamp +

People

(Reporter: gwagner, Assigned: gwagner)

References

Details

Attachments

(1 file, 2 obsolete files)

      No description provided.
Assignee: nobody → anygregor
Attached patch patch (obsolete) — Splinter Review
Attached patch patch (obsolete) — Splinter Review
Attachment #645131 - Attachment is obsolete: true
Attached patch patchSplinter Review
Also update the directoryProvider
Attachment #645154 - Attachment is obsolete: true
Attachment #645159 - Flags: review?(bent.mozilla)
Blocks: 774716
blocking-basecamp: --- → ?
Comment on attachment 645159 [details] [diff] [review]
patch

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

r=me with the nits addressed.

::: b2g/components/DirectoryProvider.js
@@ +21,5 @@
>    QueryInterface: XPCOMUtils.generateQI([Ci.nsIDirectoryServiceProvider]),
>  
>    getFile: function dp_getFile(prop, persistent) {
>  #ifdef MOZ_WIDGET_GONK
> +    let localProps = ["cachePDir", "webappsDir", "PrefD", "indexedDBPDir", "permisionDBDir"];

Ditto: 'permissionDBPDir

::: extensions/cookie/nsPermissionManager.cpp
@@ +306,5 @@
> +  nsresult rv = NS_GetSpecialDirectory(NS_APP_PERMISSION_PARENT_DIR, getter_AddRefs(permissionsFile));
> +  if (NS_FAILED(rv)) {
> +    rv = NS_GetSpecialDirectory(NS_APP_USER_PROFILE_50_DIR, getter_AddRefs(permissionsFile));
> +  }
> +  NS_ENSURE_SUCCESS(rv, nsnull);

why nsnull and not NS_ENSURE_SUCCESS(rv, NS_ERROR_UNEXPECTED) ?

::: xpcom/io/nsAppDirectoryServiceDefs.h
@@ +88,5 @@
>  #define NS_APP_STORAGE_50_FILE                  "UStor" // sqlite database used as mozStorage profile db
>  
>  #define NS_APP_INDEXEDDB_PARENT_DIR             "indexedDBPDir"
> +
> +#define NS_APP_PERMISSION_PARENT_DIR            "permisionDBDir"

I would use permissionDBPDir ('P' for parent, and also you have a typo with a missing 's')
Attachment #645159 - Flags: review+
blocking-basecamp: ? → +
Attachment #645159 - Flags: review?(bent.mozilla)
https://hg.mozilla.org/mozilla-central/rev/d9419716db6f
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla17
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: