Merge "Revert "audio policy: fix sensor privacy listener"" into udc-dev
diff --git a/services/tuner/TunerService.cpp b/services/tuner/TunerService.cpp
index e5bcf1f..9a1e8bb 100644
--- a/services/tuner/TunerService.cpp
+++ b/services/tuner/TunerService.cpp
@@ -100,8 +100,11 @@
if (fallBackToOpenDemux) {
auto status = mTuner->openDemux(&ids, &demux);
- return ::ndk::ScopedAStatus::fromServiceSpecificError(
- static_cast<int32_t>(Result::UNAVAILABLE));
+ if (status.isOk()) {
+ *_aidl_return = ::ndk::SharedRefBase::make<TunerDemux>(demux, ids[0],
+ this->ref<TunerService>());
+ }
+ return status;
} else {
int id = TunerHelper::getResourceIdFromHandle(in_demuxHandle, DEMUX);
auto status = mTuner->openDemuxById(id, &demux);