Check caller for sending media key to global priority session
am: d409d18686
Change-Id: I533ac492152a3aee906d3bf09df9dd965e1213bf
This commit is contained in:
@@ -767,6 +767,13 @@ public class MediaSessionService extends SystemService implements Monitor {
|
|||||||
+ "setup is in progress.");
|
+ "setup is in progress.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (isGlobalPriorityActive() && uid != Process.SYSTEM_UID) {
|
||||||
|
// Prevent dispatching key event through reflection while the global priority
|
||||||
|
// session is active.
|
||||||
|
Slog.i(TAG, "Only the system can dispatch media key event "
|
||||||
|
+ "to the global priority session.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
synchronized (mLock) {
|
synchronized (mLock) {
|
||||||
// If we don't have a media button receiver to fall back on
|
// If we don't have a media button receiver to fall back on
|
||||||
|
|||||||
Reference in New Issue
Block a user