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

Commit 5f24fd93 authored by SathishKumar Mani's avatar SathishKumar Mani Committed by Iliyan Malchev
Browse files

alsa_sound: fix watchdog error issue



- Issue happens when pcm_open fails after routing is done.
- Currently HAL returns zero bytes when pcm_open fails,
  Return actual bytes so that audioflinger can drop the buffer.

Bug-id: 7253359
Change-Id: I5d989539b0f9252577dc81a3ba34d467758bf717
Signed-off-by: default avatarIliyan Malchev <malchev@google.com>
parent 6ebf0aa4
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -185,7 +185,7 @@ ssize_t AudioStreamOutALSA::write(const void *buffer, size_t bytes)
        if(mHandle->handle == NULL) {
            ALOGE("write:: device open failed");
            mParent->mLock.unlock();
            return 0;
            return bytes;
        }
#ifdef QCOM_USBAUDIO_ENABLED
        if((mHandle->devices == AudioSystem::DEVICE_IN_ANLG_DOCK_HEADSET)||