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

Commit b67a637e authored by Svetoslav's avatar Svetoslav
Browse files

IndexOutOfBoundsException in the PrintSpoolerService dump.

The dump code in PrintSpoolerService was relying on being
called only as a result of "adb shell dumpsys print" which
is apparently wrong. As a result the code was making wrong
assumption about the input arguments.

bug:11046234

Change-Id: Ie38f3cc5f17cac98b808fef6d6bbeaca22a62ef0
parent 93cb8f6b
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -236,7 +236,7 @@ public final class PrintSpoolerService extends Service {
    @Override
    protected void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
        synchronized (mLock) {
            String prefix = args[0];
            String prefix = (args.length > 0) ? args[0] : "";
            String tab = "  ";

            pw.append(prefix).append("print jobs:").println();