Merge "Fix test build failure"
This commit is contained in:
committed by
Android (Google) Code Review
commit
5ebefec5bd
@ -237,7 +237,7 @@ public class ActivityTestMain extends Activity {
|
||||
Log.i(TAG, "Service disconnected " + name);
|
||||
}
|
||||
};
|
||||
if (bindService(intent, conn, Context.BIND_AUTO_CREATE, 0)) {
|
||||
if (bindServiceAsUser(intent, conn, Context.BIND_AUTO_CREATE, UserHandle.OWNER)) {
|
||||
mConnections.add(conn);
|
||||
} else {
|
||||
Toast.makeText(ActivityTestMain.this, "Failed to bind",
|
||||
@ -260,7 +260,8 @@ public class ActivityTestMain extends Activity {
|
||||
Log.i(TAG, "Service disconnected " + name);
|
||||
}
|
||||
};
|
||||
if (bindService(intent, conn, Context.BIND_AUTO_CREATE, mSecondUser)) {
|
||||
if (bindServiceAsUser(intent, conn, Context.BIND_AUTO_CREATE,
|
||||
new UserHandle(mSecondUser))) {
|
||||
mConnections.add(conn);
|
||||
} else {
|
||||
Toast.makeText(ActivityTestMain.this, "Failed to bind",
|
||||
|
Reference in New Issue
Block a user