Audio HAL default implementation: reduce logspam
Legacy BT A2DP implementation of Audio HAL may be returning EAGAIN
from get_presentation_position, this is normal and shouldn't be
logged. Otherwise we create logspam as this HAL function is called
often.
Bug: 30222631
Change-Id: I9394dbc1d53c1f4136c2d538fccd519964ff1697
Test: play music via BT A2DP
diff --git a/audio/2.0/default/Stream.cpp b/audio/2.0/default/Stream.cpp
index 62b34a3..c16a956 100644
--- a/audio/2.0/default/Stream.cpp
+++ b/audio/2.0/default/Stream.cpp
@@ -44,8 +44,8 @@
}
// static
-Result Stream::analyzeStatus(const char* funcName, int status, int ignoreError) {
- if (status != 0 && status != -ignoreError) {
+Result Stream::analyzeStatus(const char* funcName, int status, int ignoreError, int ignoreError2) {
+ if (status != 0 && status != -ignoreError && status != -ignoreError2) {
ALOGW("Error from HAL stream in function %s: %s", funcName, strerror(-status));
}
switch (status) {