Skip to content

Commit

Permalink
[RESTRICT AUTOMERGE] Correct argument order in permission check
Browse files Browse the repository at this point in the history
The function 'checkAccess' recieves the uid and pid in that order and
forwards them to checkSlicePermission in the same order. However,
checkSlicePermission expects them in the opposite order.

Bug: 135551349
Test: atest FrameworksUiServicesTests
Change-Id: I6e49efeab08f0e2a29d9830e6f81905598ae410c
  • Loading branch information
Bryan Ferris committed Jun 27, 2019
1 parent 459844b commit d2432fc
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ public Handler getHandler() {
}

protected int checkAccess(String pkg, Uri uri, int uid, int pid) {
return checkSlicePermission(uri, pkg, uid, pid, null);
return checkSlicePermission(uri, pkg, pid, uid, null);
}

private String getProviderPkg(Uri uri, int user) {
Expand Down

0 comments on commit d2432fc

Please sign in to comment.