Merge "Don't print contents of user-provided bundles." into pi-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
dac0fe910a
@@ -19,7 +19,6 @@ package com.android.server.autofill;
|
||||
import static android.Manifest.permission.MANAGE_AUTO_FILL;
|
||||
import static android.content.Context.AUTOFILL_MANAGER_SERVICE;
|
||||
|
||||
import static com.android.server.autofill.Helper.bundleToString;
|
||||
import static com.android.server.autofill.Helper.sDebug;
|
||||
import static com.android.server.autofill.Helper.sFullScreenMode;
|
||||
import static com.android.server.autofill.Helper.sPartitionMaxCount;
|
||||
@@ -193,8 +192,7 @@ public final class AutofillManagerService extends SystemService {
|
||||
if (disabledBefore == disabledNow) {
|
||||
// Nothing changed, do nothing.
|
||||
if (sDebug) {
|
||||
Slog.d(TAG, "Autofill restriction did not change for user " + userId + ": "
|
||||
+ bundleToString(newRestrictions));
|
||||
Slog.d(TAG, "Autofill restriction did not change for user " + userId);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -79,28 +79,6 @@ public final class Helper {
|
||||
throw new UnsupportedOperationException("contains static members only");
|
||||
}
|
||||
|
||||
static void append(StringBuilder builder, Bundle bundle) {
|
||||
if (bundle == null || !sVerbose) {
|
||||
builder.append("null");
|
||||
return;
|
||||
}
|
||||
final Set<String> keySet = bundle.keySet();
|
||||
builder.append("[Bundle with ").append(keySet.size()).append(" extras:");
|
||||
for (String key : keySet) {
|
||||
final Object value = bundle.get(key);
|
||||
builder.append(' ').append(key).append('=');
|
||||
builder.append((value instanceof Object[])
|
||||
? Arrays.toString((Objects[]) value) : value);
|
||||
}
|
||||
builder.append(']');
|
||||
}
|
||||
|
||||
static String bundleToString(Bundle bundle) {
|
||||
final StringBuilder builder = new StringBuilder();
|
||||
append(builder, bundle);
|
||||
return builder.toString();
|
||||
}
|
||||
|
||||
@Nullable
|
||||
static AutofillId[] toArray(@Nullable ArraySet<AutofillId> set) {
|
||||
if (set == null) return null;
|
||||
|
||||
@@ -2502,8 +2502,10 @@ final class Session implements RemoteFillService.FillServiceCallbacks, ViewState
|
||||
}
|
||||
|
||||
pw.print(prefix); pw.print("mHasCallback: "); pw.println(mHasCallback);
|
||||
pw.print(prefix); pw.print("mClientState: "); pw.println(
|
||||
Helper.bundleToString(mClientState));
|
||||
if (mClientState != null) {
|
||||
pw.print(prefix); pw.println("mClientState: "); pw.print(mClientState.getSize()); pw
|
||||
.println(" items");
|
||||
}
|
||||
pw.print(prefix); pw.print("mCompatMode: "); pw.println(mCompatMode);
|
||||
pw.print(prefix); pw.print("mUrlBar: ");
|
||||
if (mUrlBar == null) {
|
||||
|
||||
Reference in New Issue
Block a user