Closed
Bug 1485114
Opened 7 years ago
Closed 7 years ago
Avoid creating nsPermission objects in the permission manager needlessly
Categories
(Core :: Permission Manager, enhancement)
Core
Permission Manager
Tracking
()
RESOLVED
FIXED
mozilla63
Tracking | Status | |
---|---|---|
firefox63 | --- | fixed |
People
(Reporter: ehsan.akhgari, Assigned: ehsan.akhgari)
Details
Attachments
(1 file, 1 obsolete file)
5.20 KB,
patch
|
nika
:
review+
|
Details | Diff | Splinter Review |
No description provided.
Assignee | ||
Comment 1•7 years ago
|
||
Attachment #9002877 -
Flags: review?(nika)
Assignee | ||
Updated•7 years ago
|
Assignee: nobody → ehsan
Assignee | ||
Comment 2•7 years ago
|
||
Attachment #9002877 -
Attachment is obsolete: true
Attachment #9002879 -
Flags: review?(nika)
Attachment #9002877 -
Flags: review?(nika)
Comment 3•7 years ago
|
||
Comment on attachment 9002879 [details] [diff] [review]
Avoid creating nsPermission objects in the permission manager needlessly
Review of attachment 9002879 [details] [diff] [review]:
-----------------------------------------------------------------
::: extensions/cookie/nsPermissionManager.cpp
@@ +2705,5 @@
>
> nsresult
> nsPermissionManager::RemovePermissionsWithAttributes(mozilla::OriginAttributesPattern& aPattern)
> {
> + AutoTArray<Pair<nsCOMPtr<nsIPrincipal>, nsCString>, 10> permissions;
It's a shame this one is still not using the common code. I presume this was to avoid double-parsing the nsIPrincipal?
Attachment #9002879 -
Flags: review?(nika) → review+
Assignee | ||
Comment 4•7 years ago
|
||
(In reply to :Nika Layzell (digging out of backlog) from comment #3)
> Comment on attachment 9002879 [details] [diff] [review]
> Avoid creating nsPermission objects in the permission manager needlessly
>
> Review of attachment 9002879 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> ::: extensions/cookie/nsPermissionManager.cpp
> @@ +2705,5 @@
> >
> > nsresult
> > nsPermissionManager::RemovePermissionsWithAttributes(mozilla::OriginAttributesPattern& aPattern)
> > {
> > + AutoTArray<Pair<nsCOMPtr<nsIPrincipal>, nsCString>, 10> permissions;
>
> It's a shame this one is still not using the common code. I presume this was
> to avoid double-parsing the nsIPrincipal?
More because this function filters the principals stored in the permission table, but RemovePermissionEntries() filters the permission entries for each principal in the permission table. IOW the filtering happens at different levels between the two.
Pushed by eakhgari@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/9b2e26f618a4
Avoid creating nsPermission objects in the permission manager needlessly; r=nika
Comment 6•7 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 7 years ago
status-firefox63:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
You need to log in
before you can comment on or make changes to this bug.
Description
•