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

Commit e63cc205 authored by Amith Yamasani's avatar Amith Yamasani
Browse files

Pass correct user id for the extra

This was causing PrintManagerService to get a broadcast with an incorrect
userid and ended up crashing the SettingsProvider.

Bug: 10608503
Change-Id: I4693de181ddfa599d685ac9bd16ac15cea8b2e52
parent 6dde146d
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -36,6 +36,7 @@ import android.graphics.drawable.Drawable;
import android.net.Uri;
import android.os.Bundle;
import android.os.Process;
import android.os.UserHandle;
import android.preference.PreferenceActivity;
import android.provider.Settings;
import android.text.TextUtils;
@@ -470,7 +471,7 @@ public class PowerUsageDetail extends Fragment implements Button.OnClickListener
                Uri.fromParts("package", mPackages[0], null));
        intent.putExtra(Intent.EXTRA_PACKAGES, mPackages);
        intent.putExtra(Intent.EXTRA_UID, mUid);
        intent.putExtra(Intent.EXTRA_USER_HANDLE, mUid);
        intent.putExtra(Intent.EXTRA_USER_HANDLE, UserHandle.getUserId(mUid));
        getActivity().sendOrderedBroadcast(intent, null, mCheckKillProcessesReceiver, null,
                Activity.RESULT_CANCELED, null, null);
    }