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

Commit add3f1bd authored by Nate Myren's avatar Nate Myren
Browse files

Expand try/catch for DeviceConfig in AppOpsManager

Some apps, such as the shell, do not seem to be able to always access
the DeviceConfig, and get an NPE. Fail gracefully when this happens.

Test: manual
Fixes: 182907280
Change-Id: If4de34f2022c165ad8bf5a950c8a04cfd5abacc9
parent 8dc4ecd2
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -9138,7 +9138,7 @@ public class AppOpsManager {
                try {
                try {
                    sFullLog = DeviceConfig.getBoolean(DeviceConfig.NAMESPACE_PRIVACY,
                    sFullLog = DeviceConfig.getBoolean(DeviceConfig.NAMESPACE_PRIVACY,
                            FULL_LOG, false);
                            FULL_LOG, false);
                } catch (SecurityException e) {
                } catch (Exception e) {
                    // This should not happen, but it may, in rare cases
                    // This should not happen, but it may, in rare cases
                    sFullLog = false;
                    sFullLog = false;
                }
                }