Merge "Fix bug in getStorageVolumesIncludingSharedProfiles" into tm-dev am: 7f24e585e2
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18164345 Change-Id: I2e14861a77f8da89b83f3da50b562a3e364fccb9 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -3880,9 +3880,12 @@ class StorageManagerService extends IStorageManager.Stub
|
||||
match = vol.isVisibleForWrite(userId)
|
||||
|| (includeSharedProfile && vol.isVisibleForWrite(userIdSharingMedia));
|
||||
} else {
|
||||
// Return both read only and write only volumes. When includeSharedProfile is
|
||||
// true, all the volumes of userIdSharingMedia should be returned when queried
|
||||
// from the user it shares media with
|
||||
match = vol.isVisibleForUser(userId)
|
||||
|| (!vol.isVisible() && includeInvisible && vol.getPath() != null)
|
||||
|| (includeSharedProfile && vol.isVisibleForRead(userIdSharingMedia));
|
||||
|| (includeSharedProfile && vol.isVisibleForUser(userIdSharingMedia));
|
||||
}
|
||||
if (!match) continue;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user