Add BIND_INCLUDE_CAPABILITIES flag when binding to the service.
This allows headless media applications to access the location if they have the permission and is needed for AAOS apps in particular. Bug: 169242810 Bug: 156904507 Test: manual with AAOS Media app Change-Id: I1196718638fba336a815809578f643814545baf4
This commit is contained in:
@@ -185,7 +185,7 @@ public final class MediaBrowser {
|
||||
boolean bound = false;
|
||||
try {
|
||||
bound = mContext.bindService(intent, mServiceConnection,
|
||||
Context.BIND_AUTO_CREATE);
|
||||
Context.BIND_AUTO_CREATE | Context.BIND_INCLUDE_CAPABILITIES);
|
||||
} catch (Exception ex) {
|
||||
Log.e(TAG, "Failed binding to service " + mServiceComponent);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user