Skip to content

Commit aa8cac8

Browse files
Dianne Hackbornandroid code review
authored andcommitted
Merge "frameworks/base: release references of UriPermissionOwner"
2 parents 2d18c60 + 2ed5249 commit aa8cac8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

services/java/com/android/server/am/UriPermission.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,11 @@ void clearModes(int modeFlagsToClear) {
5959
if ((modeFlagsToClear&Intent.FLAG_GRANT_WRITE_URI_PERMISSION) != 0) {
6060
globalModeFlags &= ~Intent.FLAG_GRANT_WRITE_URI_PERMISSION;
6161
modeFlags &= ~Intent.FLAG_GRANT_WRITE_URI_PERMISSION;
62-
if (readOwners.size() > 0) {
62+
if (writeOwners.size() > 0) {
6363
for (UriPermissionOwner r : writeOwners) {
6464
r.removeWritePermission(this);
6565
}
66-
readOwners.clear();
66+
writeOwners.clear();
6767
}
6868
}
6969
}

0 commit comments

Comments
 (0)