summaryrefslogtreecommitdiff
Diffstat
-rw-r--r--audio_hw.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/audio_hw.c b/audio_hw.c
index 4738dea..ea885aa 100644
--- a/audio_hw.c
+++ b/audio_hw.c
@@ -1554,6 +1554,7 @@ static ssize_t out_write_legacy(struct audio_stream_out *stream, const void* buf
in_buffer, &in_frames,
(int16_t*)out->buffer, &out_frames);
in_buffer = (int16_t*)out->buffer;
+ out_buffer = in_buffer;
} else {
out_frames = in_frames;
}
@@ -1579,6 +1580,7 @@ static ssize_t out_write_legacy(struct audio_stream_out *stream, const void* buf
}
#endif
#if 1
+if (!(adev->out_device & AUDIO_DEVICE_OUT_ALL_SCO)) {
codec_type = get_sysfs_int("/sys/class/audiodsp/digital_codec");
//samesource_flag = get_sysfs_int("/sys/class/audiodsp/audio_samesource");
if (codec_type != out->last_codec_type/*samesource_flag == 0*/ && codec_type == 0) {
@@ -1586,6 +1588,7 @@ static ssize_t out_write_legacy(struct audio_stream_out *stream, const void* buf
pcm_stop(out->pcm);
}
out->last_codec_type = codec_type;
+}
#endif
if (out->is_tv_platform == 1) {
int16_t *tmp_buffer = (int16_t *)out->audioeffect_tmp_buffer;