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

Commit 41301962 authored by Yu-Ting Tseng's avatar Yu-Ting Tseng
Browse files

[temp fix] Stop broadcasting onProcessStarted.

This fixes system server crashes caused by race condition between
multiple concurrent broadcasts to IProcessObserver, likely caused by the
recently added code for broadcasting onProcessStarted. The fix removes
the newly added code.

A subsequent change will add back the implementation with proper
concurrency protection.

Test: m
Bug: 323925686
Change-Id: I3cb1df12c5146a4914c5082790f71e0c4b17e4fe
parent 1927527c
Loading
Loading
Loading
Loading
+1 −13
Original line number Diff line number Diff line
@@ -4986,19 +4986,7 @@ public final class ProcessList {
    }

    void dispatchProcessStarted(ProcessRecord app, int pid) {
        int i = mProcessObservers.beginBroadcast();
        while (i > 0) {
            i--;
            final IProcessObserver observer = mProcessObservers.getBroadcastItem(i);
            if (observer != null) {
                try {
                    observer.onProcessStarted(pid, app.uid, app.info.uid,
                            app.info.packageName, app.processName);
                } catch (RemoteException e) {
                }
            }
        }
        mProcessObservers.finishBroadcast();
        // TODO(b/323959187) Add the implementation.
    }

    void dispatchProcessDied(int pid, int uid) {