Merge "fixes mStartedUsers shoule be locked by mLock, not mVolumes" am: 1cd6248012 am: 130cb9232a am: b24828bd77

am: 29b3e92296

Change-Id: I90901200290c85b59a753c66f7021678f040f27d
This commit is contained in:
yuanhuihui
2016-09-06 23:46:14 +00:00
committed by android-build-merger

View File

@@ -922,7 +922,7 @@ class MountService extends IMountService.Stub
// Record user as started so newly mounted volumes kick off events
// correctly, then synthesize events for any already-mounted volumes.
synchronized (mVolumes) {
synchronized (mLock) {
for (int i = 0; i < mVolumes.size(); i++) {
final VolumeInfo vol = mVolumes.valueAt(i);
if (vol.isVisibleForRead(userId) && vol.isMountedReadable()) {
@@ -945,7 +945,7 @@ class MountService extends IMountService.Stub
} catch (NativeDaemonConnectorException ignored) {
}
synchronized (mVolumes) {
synchronized (mLock) {
mSystemUnlockedUsers = ArrayUtils.removeInt(mSystemUnlockedUsers, userId);
}
}