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

Commit 6853e0dc authored by Tim Murray's avatar Tim Murray
Browse files

resolve merge conflicts of 8d7b1829 to master

Change-Id: Id59ab691bfdb98cff179dfa23e3ddb185e646f53
parents 2cddef33 8d7b1829
Loading
Loading
Loading
Loading
+9 −0
Original line number Original line Diff line number Diff line
@@ -6415,6 +6415,7 @@ public class ActivityManagerService extends IActivityManager.Stub
        // the pid if we are running in multiple processes, or just pull the
        // the pid if we are running in multiple processes, or just pull the
        // next app record if we are emulating process with anonymous threads.
        // next app record if we are emulating process with anonymous threads.
        ProcessRecord app;
        ProcessRecord app;
        long startTime = SystemClock.uptimeMillis();
        if (pid != MY_PID && pid >= 0) {
        if (pid != MY_PID && pid >= 0) {
            synchronized (mPidsSelfLocked) {
            synchronized (mPidsSelfLocked) {
                app = mPidsSelfLocked.get(pid);
                app = mPidsSelfLocked.get(pid);
@@ -6493,6 +6494,8 @@ public class ActivityManagerService extends IActivityManager.Stub
            mHandler.sendMessageDelayed(msg, CONTENT_PROVIDER_PUBLISH_TIMEOUT);
            mHandler.sendMessageDelayed(msg, CONTENT_PROVIDER_PUBLISH_TIMEOUT);
        }
        }
        checkTime(startTime, "attachApplicationLocked: before bindApplication");
        if (!normalMode) {
        if (!normalMode) {
            Slog.i(TAG, "Launching preboot mode app: " + app);
            Slog.i(TAG, "Launching preboot mode app: " + app);
        }
        }
@@ -6564,6 +6567,7 @@ public class ActivityManagerService extends IActivityManager.Stub
                        .getSerial();
                        .getSerial();
//            }
//            }
            checkTime(startTime, "attachApplicationLocked: immediately before bindApplication");
            thread.bindApplication(processName, appInfo, providers, app.instrumentationClass,
            thread.bindApplication(processName, appInfo, providers, app.instrumentationClass,
                    profilerInfo, app.instrumentationArguments, app.instrumentationWatcher,
                    profilerInfo, app.instrumentationArguments, app.instrumentationWatcher,
                    app.instrumentationUiAutomationConnection, testMode,
                    app.instrumentationUiAutomationConnection, testMode,
@@ -6574,7 +6578,9 @@ public class ActivityManagerService extends IActivityManager.Stub
                    mCoreSettingsObserver.getCoreSettingsLocked(),
                    mCoreSettingsObserver.getCoreSettingsLocked(),
                    buildSerial);
                    buildSerial);
            checkTime(startTime, "attachApplicationLocked: immediately after bindApplication");
            updateLruProcessLocked(app, false, null);
            updateLruProcessLocked(app, false, null);
            checkTime(startTime, "attachApplicationLocked: after updateLruProcessLocked");
            app.lastRequestedGc = app.lastLowMemory = SystemClock.uptimeMillis();
            app.lastRequestedGc = app.lastLowMemory = SystemClock.uptimeMillis();
        } catch (Exception e) {
        } catch (Exception e) {
            // todo: Yikes!  What should we do?  For now we will try to
            // todo: Yikes!  What should we do?  For now we will try to
@@ -6613,6 +6619,7 @@ public class ActivityManagerService extends IActivityManager.Stub
        if (!badApp) {
        if (!badApp) {
            try {
            try {
                didSomething |= mServices.attachApplicationLocked(app, processName);
                didSomething |= mServices.attachApplicationLocked(app, processName);
                checkTime(startTime, "attachApplicationLocked: after mServices.attachApplicationLocked");
            } catch (Exception e) {
            } catch (Exception e) {
                Slog.wtf(TAG, "Exception thrown starting services in " + app, e);
                Slog.wtf(TAG, "Exception thrown starting services in " + app, e);
                badApp = true;
                badApp = true;
@@ -6623,6 +6630,7 @@ public class ActivityManagerService extends IActivityManager.Stub
        if (!badApp && isPendingBroadcastProcessLocked(pid)) {
        if (!badApp && isPendingBroadcastProcessLocked(pid)) {
            try {
            try {
                didSomething |= sendPendingBroadcastsLocked(app);
                didSomething |= sendPendingBroadcastsLocked(app);
                checkTime(startTime, "attachApplicationLocked: after sendPendingBroadcastsLocked");
            } catch (Exception e) {
            } catch (Exception e) {
                // If the app died trying to launch the receiver we declare it 'bad'
                // If the app died trying to launch the receiver we declare it 'bad'
                Slog.wtf(TAG, "Exception thrown dispatching broadcasts in " + app, e);
                Slog.wtf(TAG, "Exception thrown dispatching broadcasts in " + app, e);
@@ -6654,6 +6662,7 @@ public class ActivityManagerService extends IActivityManager.Stub
        if (!didSomething) {
        if (!didSomething) {
            updateOomAdjLocked();
            updateOomAdjLocked();
            checkTime(startTime, "attachApplicationLocked: after updateOomAdjLocked");
        }
        }
        return true;
        return true;