Skip to content

Commit c194016

Browse files
ChrisCraikAndroid (Google) Code Review
authored andcommitted
Merge "Use the original caller pid for computing visibility" into jb-mr1-dev
2 parents 33ee290 + 3198ef3 commit c194016

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

services/java/com/android/server/wm/WindowManagerService.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5651,12 +5651,12 @@ public void setInTouchMode(boolean mode) {
56515651
@Override
56525652
public void showStrictModeViolation(boolean on) {
56535653
if (mHeadless) return;
5654-
mH.sendMessage(mH.obtainMessage(H.SHOW_STRICT_MODE_VIOLATION, on ? 1 : 0, 0));
5654+
int pid = Binder.getCallingPid();
5655+
mH.sendMessage(mH.obtainMessage(H.SHOW_STRICT_MODE_VIOLATION, on ? 1 : 0, pid));
56555656
}
56565657

5657-
private void showStrictModeViolation(int arg) {
5658+
private void showStrictModeViolation(int arg, int pid) {
56585659
final boolean on = arg != 0;
5659-
int pid = Binder.getCallingPid();
56605660
synchronized(mWindowMap) {
56615661
// Ignoring requests to enable the red border from clients
56625662
// which aren't on screen. (e.g. Broadcast Receivers in
@@ -7647,7 +7647,7 @@ public void handleMessage(Message msg) {
76477647
}
76487648

76497649
case SHOW_STRICT_MODE_VIOLATION: {
7650-
showStrictModeViolation(msg.arg1);
7650+
showStrictModeViolation(msg.arg1, msg.arg2);
76517651
break;
76527652
}
76537653

0 commit comments

Comments
 (0)