Fix NPE in retrieveServiceLocked()

Use name.getPackageName(), not r.packageName

Change-Id: I7cc623356ff42d9923630b98df0e9fb7b0b4f58f
Fixes: 121197498
Test: boots
This commit is contained in:
Amith Yamasani
2018-12-19 18:32:44 -08:00
parent e8a25e3dbc
commit 9f96c2bf71

View File

@@ -2023,7 +2023,7 @@ public final class ActiveServices {
if (!mAm.validateAssociationAllowedLocked(callingPackage, callingUid,
name.getPackageName(), sInfo.applicationInfo.uid)) {
String msg = "association not allowed between packages "
+ callingPackage + " and " + r.packageName;
+ callingPackage + " and " + name.getPackageName();
Slog.w(TAG, "Service lookup failed: " + msg);
return new ServiceLookupResult(null, msg);
}