mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-07 20:33:58 -04:00
Merge "ASoC: msm-pcm-q6-v2: Add size check"
This commit is contained in:
commit
dcd49b01ee
1 changed files with 1 additions and 1 deletions
|
|
@ -1329,7 +1329,7 @@ static int msm_pcm_capture_copy(struct snd_pcm_substream *substream,
|
|||
offset = prtd->in_frame_info[idx].offset;
|
||||
pr_debug("Offset value = %d\n", offset);
|
||||
|
||||
if (offset >= size) {
|
||||
if (size && offset >= size) {
|
||||
pr_err("%s: Invalid dsp buf offset\n", __func__);
|
||||
ret = -EFAULT;
|
||||
q6asm_cpu_buf_release(OUT, prtd->audio_client);
|
||||
|
|
|
|||
Loading…
Reference in a new issue