Loading media/libaaudio/src/core/AAudioAudio.cpp +1 −3 Original line number Diff line number Diff line Loading @@ -565,9 +565,7 @@ AAUDIO_API aaudio_result_t AAudioStream_getTimestamp(AAudioStream* stream, int64_t *timeNanoseconds) { AudioStream *audioStream = convertAAudioStreamToAudioStream(stream); if (framePosition == nullptr) { return AAUDIO_ERROR_NULL; } else if (timeNanoseconds == nullptr) { if (framePosition == nullptr || timeNanoseconds == nullptr) { return AAUDIO_ERROR_NULL; } else if (clockid != CLOCK_MONOTONIC && clockid != CLOCK_BOOTTIME) { return AAUDIO_ERROR_ILLEGAL_ARGUMENT; Loading media/libaaudio/src/core/AAudioStreamParameters.cpp +0 −1 Original line number Diff line number Diff line Loading @@ -86,7 +86,6 @@ aaudio_result_t AAudioStreamParameters::validate() const { switch (mSessionId) { case AAUDIO_SESSION_ID_NONE: case AAUDIO_SESSION_ID_ALLOCATE: break; default: break; } Loading services/mediametrics/MediaMetricsService.cpp +2 −0 Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ nsecs_t MediaMetricsService::roundTime(nsecs_t timeNs) bool MediaMetricsService::useUidForPackage( const std::string& package, const std::string& installer) { // NOLINTBEGIN(bugprone-branch-clone) if (strchr(package.c_str(), '.') == nullptr) { return false; // not of form 'com.whatever...'; assume internal and ok } else if (strncmp(package.c_str(), "android.", 8) == 0) { Loading @@ -85,6 +86,7 @@ bool MediaMetricsService::useUidForPackage( } else { return true; // we're not sure where it came from, use uid only. } // NOLINTEND(bugprone-branch-clone) } /* static */ Loading services/mediametrics/statsd_audiorecord.cpp +4 −6 Original line number Diff line number Diff line Loading @@ -99,16 +99,14 @@ bool statsd_audiorecord(const std::shared_ptr<const mediametrics::Item>& item, } int32_t error_code = -1; if (item->getInt32("android.media.audiorecord.errcode", &error_code)) { metrics_proto.set_error_code(error_code); } else if (item->getInt32("android.media.audiorecord.lastError.code", &error_code)) { if (item->getInt32("android.media.audiorecord.errcode", &error_code) || item->getInt32("android.media.audiorecord.lastError.code", &error_code)) { metrics_proto.set_error_code(error_code); } std::string error_function; if (item->getString("android.media.audiorecord.errfunc", &error_function)) { metrics_proto.set_error_function(error_function); } else if (item->getString("android.media.audiorecord.lastError.at", &error_function)) { if (item->getString("android.media.audiorecord.errfunc", &error_function) || item->getString("android.media.audiorecord.lastError.at", &error_function)) { metrics_proto.set_error_function(error_function); } Loading Loading
media/libaaudio/src/core/AAudioAudio.cpp +1 −3 Original line number Diff line number Diff line Loading @@ -565,9 +565,7 @@ AAUDIO_API aaudio_result_t AAudioStream_getTimestamp(AAudioStream* stream, int64_t *timeNanoseconds) { AudioStream *audioStream = convertAAudioStreamToAudioStream(stream); if (framePosition == nullptr) { return AAUDIO_ERROR_NULL; } else if (timeNanoseconds == nullptr) { if (framePosition == nullptr || timeNanoseconds == nullptr) { return AAUDIO_ERROR_NULL; } else if (clockid != CLOCK_MONOTONIC && clockid != CLOCK_BOOTTIME) { return AAUDIO_ERROR_ILLEGAL_ARGUMENT; Loading
media/libaaudio/src/core/AAudioStreamParameters.cpp +0 −1 Original line number Diff line number Diff line Loading @@ -86,7 +86,6 @@ aaudio_result_t AAudioStreamParameters::validate() const { switch (mSessionId) { case AAUDIO_SESSION_ID_NONE: case AAUDIO_SESSION_ID_ALLOCATE: break; default: break; } Loading
services/mediametrics/MediaMetricsService.cpp +2 −0 Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ nsecs_t MediaMetricsService::roundTime(nsecs_t timeNs) bool MediaMetricsService::useUidForPackage( const std::string& package, const std::string& installer) { // NOLINTBEGIN(bugprone-branch-clone) if (strchr(package.c_str(), '.') == nullptr) { return false; // not of form 'com.whatever...'; assume internal and ok } else if (strncmp(package.c_str(), "android.", 8) == 0) { Loading @@ -85,6 +86,7 @@ bool MediaMetricsService::useUidForPackage( } else { return true; // we're not sure where it came from, use uid only. } // NOLINTEND(bugprone-branch-clone) } /* static */ Loading
services/mediametrics/statsd_audiorecord.cpp +4 −6 Original line number Diff line number Diff line Loading @@ -99,16 +99,14 @@ bool statsd_audiorecord(const std::shared_ptr<const mediametrics::Item>& item, } int32_t error_code = -1; if (item->getInt32("android.media.audiorecord.errcode", &error_code)) { metrics_proto.set_error_code(error_code); } else if (item->getInt32("android.media.audiorecord.lastError.code", &error_code)) { if (item->getInt32("android.media.audiorecord.errcode", &error_code) || item->getInt32("android.media.audiorecord.lastError.code", &error_code)) { metrics_proto.set_error_code(error_code); } std::string error_function; if (item->getString("android.media.audiorecord.errfunc", &error_function)) { metrics_proto.set_error_function(error_function); } else if (item->getString("android.media.audiorecord.lastError.at", &error_function)) { if (item->getString("android.media.audiorecord.errfunc", &error_function) || item->getString("android.media.audiorecord.lastError.at", &error_function)) { metrics_proto.set_error_function(error_function); } Loading