Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 71c90911 authored by Tomoharu Kasahara's avatar Tomoharu Kasahara
Browse files

Keep verbose log statements, but silence them by default

Do not strip out ALOGV statements in production builds,
but keep them silent by setting the default log level
for AudioPolicyManager to D.

Bug: 113756665
Test: adb shell setprop log.tag.APM_AudioPolicyManager V
      check logcat for verbose log messages from APM
Change-Id: I0129a07e3afa11634945763b8d976699ce13093e
parent a0fd81b4
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -15,7 +15,12 @@
 */

#define LOG_TAG "APM_AudioPolicyManager"
//#define LOG_NDEBUG 0

// Need to keep the log statements even in production builds
// to enable VERBOSE logging dynamically.
// You can enable VERBOSE logging as follows:
// adb shell setprop log.tag.APM_AudioPolicyManager V
#define LOG_NDEBUG 0

//#define VERY_VERBOSE_LOGGING
#ifdef VERY_VERBOSE_LOGGING
@@ -4169,6 +4174,9 @@ status_t AudioPolicyManager::initialize() {
        status = NO_INIT;
    }

    // Silence ALOGV statements
    property_set("log.tag." LOG_TAG, "D");

    updateDevicesAndOutputs();
    return status;
}