Skip to content

Commit

Permalink
gmscompat: enable Play {Asset, Feature} Delivery
Browse files Browse the repository at this point in the history
Play Store uses a similar getRunningAppProcesses()-based "is client foreground"
check as Play Services does, so enable the same workaround for it as well.
  • Loading branch information
muhomorr authored and thestinger committed Jan 13, 2022
1 parent 55c188a commit cd8174a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion core/java/android/app/ActivityManager.java
Expand Up @@ -3374,7 +3374,7 @@ public boolean setProcessMemoryTrimLevel(String process, int userId, int level)
public List<RunningAppProcessInfo> getRunningAppProcesses() {
try {
List<RunningAppProcessInfo> res = getService().getRunningAppProcesses();
if (GmsCompat.isPlayServices()) {
if (GmsCompat.isEnabled()) {
res = GmsHooks.addRecentlyBoundPids(mContext, res);
}
return res;
Expand Down
2 changes: 1 addition & 1 deletion core/java/android/os/Binder.java
Expand Up @@ -1142,7 +1142,7 @@ private boolean execTransact(int code, long dataObj, long replyObj,
// At that point, the parcel request headers haven't been parsed so we do not know what
// WorkSource the caller has set. Use calling uid as the default.
final int callingUid = Binder.getCallingUid();
if (GmsCompat.isPlayServices()) {
if (GmsCompat.isEnabled()) {
if (callingUid >= Process.FIRST_APPLICATION_UID && callingUid != mPreviousUid) {
// harmless race
mPreviousUid = callingUid;
Expand Down

0 comments on commit cd8174a

Please sign in to comment.