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

Commit bde9bc36 authored by Collin Fijalkovich's avatar Collin Fijalkovich
Browse files

Avoid TransferPipe for local dumpCacheInfo calls

Make a process-local call to PropertyInvalidatedCache instead of dumping
cache state through a TransferPipe to avoid blocking when the pipe
buffer fills.

Bug: 180051995
Test: Ran dumpsys cacheinfo and validated output
Change-Id: I1e4ab8e1d09b98b379d81079fd26ff2129b5b65a
parent 989bc8cd
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -172,6 +172,7 @@ import android.app.NotificationManager;
import android.app.PendingIntent;
import android.app.ProcessMemoryState;
import android.app.ProfilerInfo;
import android.app.PropertyInvalidatedCache;
import android.app.WaitResult;
import android.app.backup.BackupManager.OperationType;
import android.app.backup.IBackupManager;
@@ -9835,6 +9836,10 @@ public class ActivityManagerService extends IActivityManager.Stub
            if (thread != null) {
                pw.println("\n\n** Cache info for pid " + pid + " [" + r.processName + "] **");
                pw.flush();
                if (pid == MY_PID) {
                    PropertyInvalidatedCache.dumpCacheInfo(fd, args);
                    continue;
                }
                try {
                    TransferPipe tp = new TransferPipe();
                    try {