Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 32fee770 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "LOCATION_PROVIDERS_ALLOWED fixes"

parents 4914ed2a 10b19601
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -2103,10 +2103,6 @@ public final class Settings {
    private static final String TAG = "Settings";
    private static final boolean LOCAL_LOGV = false;
    // Lock ensures that when enabling/disabling the master location switch, we don't end up
    // with a partial enable/disable state in multi-threaded situations.
    private static final Object mLocationSettingsLock = new Object();
    // Used in system server calling uid workaround in call()
    private static boolean sInSystemServer = false;
    private static final Object sInSystemServerLock = new Object();
+6 −6
Original line number Diff line number Diff line
@@ -1521,14 +1521,14 @@ public class SettingsProvider extends ContentProvider {
            return false;
        }

        // Mutate the value.
        synchronized (mLock) {
            // Special cases for location providers (sigh).
            if (Settings.Secure.LOCATION_PROVIDERS_ALLOWED.equals(name)) {
                return updateLocationProvidersAllowedLocked(value, tag, owningUserId, makeDefault,
                        forceNotify);
            }

        // Mutate the value.
        synchronized (mLock) {
            switch (operation) {
                case MUTATION_OPERATION_INSERT: {
                    return mSettingsRegistry.insertSettingLocked(SETTINGS_TYPE_SECURE,