summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRitu Sharma <quic_ritushar@quicinc.com>2022-05-11 17:26:04 +0530
committerGerrit - the friendly Code Review server <code-review@localhost>2022-05-31 21:37:16 -0700
commit90bfae92b2558dccc322ad158157ff70ee0c9623 (patch)
tree49d7d2037e8b952c709e655e4e655dc7c28b846d
parentec1716dead52b49806dcb787033dc60eb9eb4df8 (diff)
hal: TypeCast the return value of GetFramesWritten API.
Typecast the return value of GetFramesWritten API to uint32_t, as the expected dsp_frames values in get_render_position is uint32_t. Change-Id: I58d9e7f67b6575edf0ac95c5f89f9358373db011
-rw-r--r--hal/AudioStream.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/hal/AudioStream.cpp b/hal/AudioStream.cpp
index 5b42b8fd..02ef32dc 100644
--- a/hal/AudioStream.cpp
+++ b/hal/AudioStream.cpp
@@ -754,12 +754,8 @@ static int out_get_render_position(const struct audio_stream_out *stream,
case PAL_STREAM_PCM_OFFLOAD:
case PAL_STREAM_LOW_LATENCY:
case PAL_STREAM_DEEP_BUFFER:
- ret = astream_out->GetFramesWritten(NULL);
- if (ret < 0) {
- AHAL_ERR("Get DSP Frames failed %d", ret);
- return ret;
- }
- *dsp_frames = ret;
+ frames = astream_out->GetFramesWritten(NULL);
+ *dsp_frames = (uint32_t) frames;
break;
default:
break;