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

Commit 19b728ba authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "am dumpheap throws error when arguments are after file" into main am: 7e0989d9

parents 9db8c9c4 7e0989d9
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1353,6 +1353,12 @@ final class ActivityManagerShellCommand extends ShellCommand {
            heapFile = "/data/local/tmp/heapdump-" + logNameTimeString + ".prof";
        }

        String argAfterHeapFile = getNextArg();
        if (argAfterHeapFile != null) {
            err.println("Error: Arguments cannot be placed after the heap file");
            return -1;
        }

        // Writes an error message to stderr on failure
        ParcelFileDescriptor fd = openFileForSystem(heapFile, "w");
        if (fd == null) {