Loading core/java/android/os/UserManager.java +0 −3 Original line number Diff line number Diff line Loading @@ -929,9 +929,6 @@ public class UserManager { if (guest != null) { Settings.Secure.putStringForUser(context.getContentResolver(), Settings.Secure.SKIP_FIRST_USE_HINTS, "1", guest.id); mService.setUserRestriction(DISALLOW_SMS, true, guest.id); mService.setUserRestriction(DISALLOW_INSTALL_UNKNOWN_SOURCES, true, guest.id); } } catch (RemoteException re) { Log.w(TAG, "Could not create a user", re); Loading services/core/java/com/android/server/pm/UserManagerService.java +6 −0 Original line number Diff line number Diff line Loading @@ -652,6 +652,7 @@ public class UserManagerService extends IUserManager.Stub { private void initDefaultGuestRestrictions() { synchronized (mGuestRestrictions) { if (mGuestRestrictions.isEmpty()) { mGuestRestrictions.putBoolean(UserManager.DISALLOW_INSTALL_UNKNOWN_SOURCES, true); mGuestRestrictions.putBoolean(UserManager.DISALLOW_OUTGOING_CALLS, true); mGuestRestrictions.putBoolean(UserManager.DISALLOW_SMS, true); } Loading Loading @@ -1652,6 +1653,11 @@ public class UserManagerService extends IUserManager.Stub { } updateUserIds(); Bundle restrictions = new Bundle(); if (isGuest) { synchronized (mGuestRestrictions) { restrictions.putAll(mGuestRestrictions); } } synchronized (mRestrictionsLock) { mBaseUserRestrictions.append(userId, restrictions); } Loading Loading
core/java/android/os/UserManager.java +0 −3 Original line number Diff line number Diff line Loading @@ -929,9 +929,6 @@ public class UserManager { if (guest != null) { Settings.Secure.putStringForUser(context.getContentResolver(), Settings.Secure.SKIP_FIRST_USE_HINTS, "1", guest.id); mService.setUserRestriction(DISALLOW_SMS, true, guest.id); mService.setUserRestriction(DISALLOW_INSTALL_UNKNOWN_SOURCES, true, guest.id); } } catch (RemoteException re) { Log.w(TAG, "Could not create a user", re); Loading
services/core/java/com/android/server/pm/UserManagerService.java +6 −0 Original line number Diff line number Diff line Loading @@ -652,6 +652,7 @@ public class UserManagerService extends IUserManager.Stub { private void initDefaultGuestRestrictions() { synchronized (mGuestRestrictions) { if (mGuestRestrictions.isEmpty()) { mGuestRestrictions.putBoolean(UserManager.DISALLOW_INSTALL_UNKNOWN_SOURCES, true); mGuestRestrictions.putBoolean(UserManager.DISALLOW_OUTGOING_CALLS, true); mGuestRestrictions.putBoolean(UserManager.DISALLOW_SMS, true); } Loading Loading @@ -1652,6 +1653,11 @@ public class UserManagerService extends IUserManager.Stub { } updateUserIds(); Bundle restrictions = new Bundle(); if (isGuest) { synchronized (mGuestRestrictions) { restrictions.putAll(mGuestRestrictions); } } synchronized (mRestrictionsLock) { mBaseUserRestrictions.append(userId, restrictions); } Loading