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

Commit 18998e30 authored by Eun-Jeong Shin's avatar Eun-Jeong Shin Committed by Automerger Merge Worker
Browse files

Merge changes from topic "presubmit-am-6809d34469994644a50f20911d86acf1" into...

Merge changes from topic "presubmit-am-6809d34469994644a50f20911d86acf1" into tm-mainline-prod am: ef171fb8

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17722828



Change-Id: I7b1372891da683648e51248ca35438ee0cfd8f60
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 976d9380 ef171fb8
Loading
Loading
Loading
Loading
+12 −3
Original line number Diff line number Diff line
@@ -116,6 +116,10 @@ public class LogAccessDialogActivity extends Activity implements
        }

        mPackageName = intent.getStringExtra(Intent.EXTRA_PACKAGE_NAME);
        if (mPackageName == null || mPackageName.length() == 0) {
            throw new NullPointerException("Package Name is null");
        }

        mUid = intent.getIntExtra("com.android.server.logcat.uid", 0);
        mGid = intent.getIntExtra("com.android.server.logcat.gid", 0);
        mPid = intent.getIntExtra("com.android.server.logcat.pid", 0);
@@ -154,12 +158,17 @@ public class LogAccessDialogActivity extends Activity implements
        CharSequence appLabel = pm.getApplicationInfoAsUser(callingPackage,
                PackageManager.MATCH_DIRECT_BOOT_AUTO,
                UserHandle.getUserId(uid)).loadLabel(pm);
        if (appLabel == null) {
        if (appLabel == null || appLabel.length() == 0) {
            throw new NameNotFoundException("Application Label is null");
        }

        return context.getString(com.android.internal.R.string.log_access_confirmation_title,
            appLabel);
        String titleString = context.getString(
                com.android.internal.R.string.log_access_confirmation_title, appLabel);
        if (titleString == null || titleString.length() == 0) {
            throw new NullPointerException("Title is null");
        }

        return titleString;
    }

    /**