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

Commit aa6e2128 authored by Narayan Kamath's avatar Narayan Kamath Committed by Tim Murray
Browse files

Revert "Close print writers"

This reverts commit 390b2423.

The reverted change closed the output PrintWriter too early
and led to truncated dumps.

Bug: 74423421
Change-Id: I62902f2aa20be460b6dec42e811b21bf953fcfe3
Test: manual
(cherry picked from commit 1af397c9)
parent 828ffa45
Loading
Loading
Loading
Loading
+64 −68
Original line number Diff line number Diff line
@@ -18890,7 +18890,7 @@ public class PackageManagerService extends IPackageManager.Stub
        return true;
    }
    private static final class ClearStorageConnection implements ServiceConnection {
    private final class ClearStorageConnection implements ServiceConnection {
        IMediaContainerService mContainerService;
        @Override
@@ -21611,7 +21611,7 @@ Slog.v(TAG, ":: stepped forward, applying functor at tag " + parser.getName());
                // the given package is involved with.
                if (dumpState.onTitlePrinted()) pw.println();
                try (final IndentingPrintWriter ipw = new IndentingPrintWriter(pw, "  ", 120)) {
                final IndentingPrintWriter ipw = new IndentingPrintWriter(pw, "  ", 120);
                ipw.println();
                ipw.println("Frozen packages:");
                ipw.increaseIndent();
@@ -21624,12 +21624,11 @@ Slog.v(TAG, ":: stepped forward, applying functor at tag " + parser.getName());
                }
                ipw.decreaseIndent();
            }
            }
            if (!checkin && dumpState.isDumping(DumpState.DUMP_VOLUMES) && packageName == null) {
                if (dumpState.onTitlePrinted()) pw.println();
                try (final IndentingPrintWriter ipw = new IndentingPrintWriter(pw, "  ", 120)) {
                final IndentingPrintWriter ipw = new IndentingPrintWriter(pw, "  ", 120);
                ipw.println();
                ipw.println("Loaded volumes:");
                ipw.increaseIndent();
@@ -21642,7 +21641,6 @@ Slog.v(TAG, ":: stepped forward, applying functor at tag " + parser.getName());
                }
                ipw.decreaseIndent();
            }
            }
            if (!checkin && dumpState.isDumping(DumpState.DUMP_SERVICE_PERMISSIONS)
                    && packageName == null) {
@@ -21770,7 +21768,7 @@ Slog.v(TAG, ":: stepped forward, applying functor at tag " + parser.getName());
    }
    private void dumpDexoptStateLPr(PrintWriter pw, String packageName) {
        try (final IndentingPrintWriter ipw = new IndentingPrintWriter(pw, "  ")) {
        final IndentingPrintWriter ipw = new IndentingPrintWriter(pw, "  ");
        ipw.println();
        ipw.println("Dexopt state:");
        ipw.increaseIndent();
@@ -21795,10 +21793,9 @@ Slog.v(TAG, ":: stepped forward, applying functor at tag " + parser.getName());
            ipw.decreaseIndent();
        }
    }
    }
    private void dumpCompilerStatsLPr(PrintWriter pw, String packageName) {
        try (final IndentingPrintWriter ipw = new IndentingPrintWriter(pw, "  ")) {
        final IndentingPrintWriter ipw = new IndentingPrintWriter(pw, "  ");
        ipw.println();
        ipw.println("Compiler stats:");
        ipw.increaseIndent();
@@ -21828,7 +21825,6 @@ Slog.v(TAG, ":: stepped forward, applying functor at tag " + parser.getName());
            ipw.decreaseIndent();
        }
    }
    }
    private String dumpDomainString(String packageName) {
        List<IntentFilterVerificationInfo> iviList = getIntentFilterVerifications(packageName)