Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cf229d1d authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 10786926 from 0d033113 to udc-qpr1-release

Change-Id: I207baf9076728b7feab053e5f454310a91d23f7e
parents e0c8d538 0d033113
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -2513,9 +2513,7 @@ public class OomAdjuster {
                            }
                        }

                        if (schedGroup < SCHED_GROUP_TOP_APP
                                && cr.hasFlag(Context.BIND_SCHEDULE_LIKE_TOP_APP)
                                && clientIsSystem) {
                        if (cr.hasFlag(Context.BIND_SCHEDULE_LIKE_TOP_APP) && clientIsSystem) {
                            schedGroup = SCHED_GROUP_TOP_APP;
                            scheduleLikeTopApp = true;
                        }
+7 −0
Original line number Diff line number Diff line
@@ -1862,6 +1862,13 @@ public class MockingOomAdjusterTests {
        assertProcStates(app2, PROCESS_STATE_FOREGROUND_SERVICE, PERCEPTIBLE_APP_ADJ,
                SCHED_GROUP_DEFAULT);
        assertBfsl(app2);

        bindService(client2, app1, null, 0, mock(IBinder.class));
        bindService(app1, client2, null, 0, mock(IBinder.class));
        client2.mServices.setHasForegroundServices(false, 0, /* hasNoneType=*/false);
        updateOomAdj(app1, client1, client2);
        assertProcStates(app1, PROCESS_STATE_IMPORTANT_FOREGROUND, VISIBLE_APP_ADJ,
                SCHED_GROUP_TOP_APP);
    }

    @SuppressWarnings("GuardedBy")