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

Commit 11bf4f45 authored by Robert Greenwalt's avatar Robert Greenwalt
Browse files

Fix dump to not require extra permissions.

Otherwise bugreports fail to collect the information.
Alternatively we could require you have the dump permission
AND whatever else, but that seems silly - you already have
permission to collect system dumps so they should work.

bug:19134027
Change-Id: I0f6bf3029f6230c759b94e04235d32c7a06ccea3
parent e70972cf
Loading
Loading
Loading
Loading
+49 −44
Original line number Diff line number Diff line
@@ -1541,6 +1541,8 @@ public class SubscriptionController extends ISub.Stub {
    public void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
        mContext.enforceCallingOrSelfPermission(android.Manifest.permission.DUMP,
                "Requires DUMP");
        final long token = Binder.clearCallingIdentity();
        try {
            pw.println("SubscriptionController:");
            pw.println(" defaultSubId=" + getDefaultSubId());
            pw.println(" defaultDataSubId=" + getDefaultDataSubId());
@@ -1588,5 +1590,8 @@ public class SubscriptionController extends ISub.Stub {
            pw.flush();
            pw.println("++++++++++++++++++++++++++++++++");
            pw.flush();
        } finally {
            Binder.restoreCallingIdentity(token);
        }
    }
}