Merge "Revert "Enforce declared permissions on getCellularBatteryStats() and getWifiBatteryStats()"" into sc-dev

This commit is contained in:
Sorin Basca
2021-06-15 14:46:47 +00:00
committed by Android (Google) Code Review

View File

@@ -2499,7 +2499,6 @@ public final class BatteryStatsService extends IBatteryStats.Stub
* @hide * @hide
*/ */
public CellularBatteryStats getCellularBatteryStats() { public CellularBatteryStats getCellularBatteryStats() {
enforceCallingPermission();
// Wait for the completion of pending works if there is any // Wait for the completion of pending works if there is any
awaitCompletion(); awaitCompletion();
synchronized (mStats) { synchronized (mStats) {
@@ -2512,7 +2511,6 @@ public final class BatteryStatsService extends IBatteryStats.Stub
* @hide * @hide
*/ */
public WifiBatteryStats getWifiBatteryStats() { public WifiBatteryStats getWifiBatteryStats() {
enforceCallingPermission();
// Wait for the completion of pending works if there is any // Wait for the completion of pending works if there is any
awaitCompletion(); awaitCompletion();
synchronized (mStats) { synchronized (mStats) {