Add AudioTrack and AudioRecord flag checks
Verify that the requested flags are compatible with the input
or output flags when creating and AudioRecord or AudioTrack
Get rid of IAudioFlinger::track_flags_t which was redundant
with audio_input_flags_t and audio_output_flags_t.
Change-Id: I0dd9232f857b2737e99a8c668806e45bce09cdbd
diff --git a/services/audioflinger/PatchPanel.cpp b/services/audioflinger/PatchPanel.cpp
index f8671b5..0699a15 100644
--- a/services/audioflinger/PatchPanel.cpp
+++ b/services/audioflinger/PatchPanel.cpp
@@ -437,7 +437,7 @@
format,
frameCount,
NULL,
- IAudioFlinger::TRACK_DEFAULT);
+ AUDIO_INPUT_FLAG_NONE);
if (patch->mPatchRecord == 0) {
return NO_MEMORY;
}
@@ -457,7 +457,7 @@
format,
frameCount,
patch->mPatchRecord->buffer(),
- IAudioFlinger::TRACK_DEFAULT);
+ AUDIO_OUTPUT_FLAG_NONE);
if (patch->mPatchTrack == 0) {
return NO_MEMORY;
}