Clear calling identity in BMS.backupNow
BMS.backupNow is called from GMSCore, which has a different calling identity than the framework. This causes an IllegalArgumentException due to uid mismatch when backupNow tries to schedule a job. This occurs when the following conditions are combined: 1) Battery saver mode enabled 2) Network change detected 3) Backup pass is scheduled for now Bug: 79441902 Test: 1) m -j RunFrameworksServicesRoboTests 2) Manual: Enabled battery saver, modified code to run backupNow with each network change and overwrite previously scheduled KeyValueJob. Then, change wifi to trigger scheduling the KeyValueJob. Verified: - IllegalStateException b/c of uid mismatch without change - No exception and correct calling uid with change Change-Id: Iac90cd435e3fc32ff5428236aa15507b36aa833d
Loading
Please register or sign in to comment