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

Commit 757da37e authored by JW Wang's avatar JW Wang
Browse files

updateConfigs() might throw during tests (3/n)

The callback might be run in-between setUp() and tearDown() when
the permission READ_DEVICE_CONFIG has been dropped and crash tests.

Bug: 178675924
Test: atest PackageWatchdogTest
Change-Id: Iefd31d08f71340706b64d84d44c41151b21193bf
parent a6fedf6e
Loading
Loading
Loading
Loading
+5 −1
Original line number Original line Diff line number Diff line
@@ -982,7 +982,11 @@ public class PackageWatchdog {
                    if (!DeviceConfig.NAMESPACE_ROLLBACK.equals(properties.getNamespace())) {
                    if (!DeviceConfig.NAMESPACE_ROLLBACK.equals(properties.getNamespace())) {
                        return;
                        return;
                    }
                    }
                    try {
                        updateConfigs();
                        updateConfigs();
                    } catch (Exception ignore) {
                        Slog.w(TAG, "Failed to reload device config changes");
                    }
                });
                });
    }
    }