Merge "On CPS rebind, check if package is allowed"

This commit is contained in:
Beverly Tai
2018-09-12 15:13:25 +00:00
committed by Android (Google) Code Review

View File

@@ -694,7 +694,8 @@ abstract public class ManagedServices {
for (int userId : userIds) {
if (enabled) {
if (isPackageOrComponentAllowed(component.toString(), userId)) {
if (isPackageOrComponentAllowed(component.toString(), userId)
|| isPackageOrComponentAllowed(component.getPackageName(), userId)) {
registerServiceLocked(component, userId);
} else {
Slog.d(TAG, component + " no longer has permission to be bound");