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

Commit a3100314 authored by Wink Saville's avatar Wink Saville Committed by Android (Google) Code Review
Browse files

Merge "Remove some PII." into gingerbread

parents 354954a0 a4288074
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -5267,7 +5267,14 @@ public class Intent implements Parcelable, Cloneable {
                b.append(' ');
            }
            first = false;
            b.append("dat=").append(mData);
            b.append("dat=");
            if (mData.getScheme().equalsIgnoreCase("tel")) {
                b.append("tel:xxx-xxx-xxxx");
            } else if (mData.getScheme().equalsIgnoreCase("smsto")) {
                b.append("smsto:xxx-xxx-xxxx");
            } else {
                b.append(mData);
            }
        }
        if (mType != null) {
            if (!first) {
+1 −1
Original line number Diff line number Diff line
@@ -411,7 +411,7 @@ public class SyncStorageEngine extends Handler {
    }

    public void setSyncAutomatically(Account account, String providerName, boolean sync) {
        Log.d(TAG, "setSyncAutomatically: " + account + ", provider " + providerName
        Log.d(TAG, "setSyncAutomatically: " + /*account +*/ ", provider " + providerName
                + " -> " + sync);
        synchronized (mAuthorities) {
            AuthorityInfo authority = getOrCreateAuthorityLocked(account, providerName, -1, false);
+2 −3
Original line number Diff line number Diff line
@@ -1205,9 +1205,8 @@ public final class Telephony {
            }

            Uri uri = uriBuilder.build();
            if (DEBUG) {
                Log.v(TAG, "getOrCreateThreadId uri: " + uri);
            }
            //if (DEBUG) Log.v(TAG, "getOrCreateThreadId uri: " + uri);

            Cursor cursor = SqliteWrapper.query(context, context.getContentResolver(),
                    uri, ID_PROJECTION, null, null, null);
            if (DEBUG) {
+4 −4
Original line number Diff line number Diff line
@@ -383,8 +383,8 @@ public class CallerInfo {
     */
    public String toString() {
        return new StringBuilder(384)
                .append("\nname: " + name)
                .append("\nphoneNumber: " + phoneNumber)
                .append("\nname: " + /*name*/ "nnnnnn")
                .append("\nphoneNumber: " + /*phoneNumber*/ "xxxxxxx")
                .append("\ncnapName: " + cnapName)
                .append("\nnumberPresentation: " + numberPresentation)
                .append("\nnamePresentation: " + namePresentation)
@@ -395,8 +395,8 @@ public class CallerInfo {
                .append("\nphotoResource: " + photoResource)
                .append("\nperson_id: " + person_id)
                .append("\nneedUpdate: " + needUpdate)
                .append("\ncontactRefUri: " + contactRefUri)
                .append("\ncontactRingtoneUri: " + contactRefUri)
                .append("\ncontactRefUri: " + /*contactRefUri*/ "xxxxxxx")
                .append("\ncontactRingtoneUri: " + /*contactRefUri*/ "xxxxxxx")
                .append("\nshouldSendToVoicemail: " + shouldSendToVoicemail)
                .append("\ncachedPhoto: " + cachedPhoto)
                .append("\nisCachedPhotoCurrent: " + isCachedPhotoCurrent)
+20 −6
Original line number Diff line number Diff line
@@ -135,7 +135,7 @@ public class CallerInfoAsyncQuery {
                } else {

                    if (DBG) log("Processing event: " + cw.event + " token (arg1): " + msg.arg1 +
                            " command: " + msg.what + " query URI: " + args.uri);
                        " command: " + msg.what + " query URI: " + sanitizeUriToString(args.uri));

                    switch (cw.event) {
                        case EVENT_NEW_QUERY:
@@ -297,7 +297,7 @@ public class CallerInfoAsyncQuery {
            OnQueryCompleteListener listener, Object cookie) {
        if (DBG) {
            log("##### CallerInfoAsyncQuery startQuery()... #####");
            log("- number: " + number);
            log("- number: " + /*number*/ "xxxxxxx");
            log("- cookie: " + cookie);
        }

@@ -309,7 +309,7 @@ public class CallerInfoAsyncQuery {

        if (PhoneNumberUtils.isUriNumber(number)) {
            // "number" is really a SIP address.
            if (DBG) log("  - Treating number as a SIP address: " + number);
            if (DBG) log("  - Treating number as a SIP address: " + /*number*/ "xxxxxxx");

            // We look up SIP addresses directly in the Data table:
            contactRef = Data.CONTENT_URI;
@@ -341,7 +341,7 @@ public class CallerInfoAsyncQuery {
        }

        if (DBG) {
            log("==> contactRef: " + contactRef);
            log("==> contactRef: " + sanitizeUriToString(contactRef));
            log("==> selection: " + selection);
            if (selectionArgs != null) {
                for (int i = 0; i < selectionArgs.length; i++) {
@@ -383,8 +383,8 @@ public class CallerInfoAsyncQuery {
     */
    public void addQueryListener(int token, OnQueryCompleteListener listener, Object cookie) {

        if (DBG) log("adding listener to query: " + mHandler.mQueryUri + " handler: " +
                mHandler.toString());
        if (DBG) log("adding listener to query: " + sanitizeUriToString(mHandler.mQueryUri) +
                " handler: " + mHandler.toString());

        //create cookieWrapper, add query request to end of queue.
        CookieWrapper cw = new CookieWrapper();
@@ -418,6 +418,20 @@ public class CallerInfoAsyncQuery {
        mHandler = null;
    }

    private static String sanitizeUriToString(Uri uri) {
        if (uri != null) {
            String uriString = uri.toString();
            int indexOfLastSlash = uriString.lastIndexOf('/');
            if (indexOfLastSlash > 0) {
                return uriString.substring(0, indexOfLastSlash) + "/xxxxxxx";
            } else {
                return uriString;
            }
        } else {
            return "";
        }
    }

    /**
     * static logging method
     */
Loading