commit | 82db269d4797cb9909988b723d91fa2094a74b38 | [log] [tgz] |
---|---|---|
author | Eric Laurent <elaurent@google.com> | Fri Aug 07 13:59:42 2015 -0700 |
committer | Eric Laurent <elaurent@google.com> | Fri Aug 07 15:23:46 2015 -0700 |
tree | 77f2ff4451760a09704ab7676f9e680e9af0729a | |
parent | aa7a4eae1cc93ccf90e273b9634f3a125b0b3565 [diff] [blame] |
audio policy: protect capture from telephony RX path. Add permission check if the capture device selected is telephony RX path. Bug: 23017158. Change-Id: Iaa34d836e6cf46b7cbbf2483fcd4306dcd27ce90
diff --git a/services/audiopolicy/managerdefault/AudioPolicyManager.cpp b/services/audiopolicy/managerdefault/AudioPolicyManager.cpp index fc27789..e7f6864 100644 --- a/services/audiopolicy/managerdefault/AudioPolicyManager.cpp +++ b/services/audiopolicy/managerdefault/AudioPolicyManager.cpp
@@ -1351,6 +1351,8 @@ } else if (audio_is_remote_submix_device(device)) { address = String8("0"); *inputType = API_INPUT_MIX_CAPTURE; + } else if (device == AUDIO_DEVICE_IN_TELEPHONY_RX) { + *inputType = API_INPUT_TELEPHONY_RX; } else { *inputType = API_INPUT_LEGACY; }