mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
mISDN/dsp_cmx.c: fix size checks
The checks for ensuring that the array indices are inside the range were flipped. Reported-by: Adrian Bunk <[email protected]> Signed-off-by: Adrian Bunk <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
parent
6bff338bb6
commit
9e9540b8f7
1 changed files with 2 additions and 2 deletions
|
|
@ -452,10 +452,10 @@ one_member:
|
|||
if (finddsp->features.pcm_id == dsp->features.pcm_id) {
|
||||
if (finddsp->pcm_slot_rx >= 0 &&
|
||||
finddsp->pcm_slot_rx < sizeof(freeslots))
|
||||
freeslots[finddsp->pcm_slot_tx] = 0;
|
||||
freeslots[finddsp->pcm_slot_rx] = 0;
|
||||
if (finddsp->pcm_slot_tx >= 0 &&
|
||||
finddsp->pcm_slot_tx < sizeof(freeslots))
|
||||
freeslots[finddsp->pcm_slot_rx] = 0;
|
||||
freeslots[finddsp->pcm_slot_tx] = 0;
|
||||
}
|
||||
}
|
||||
i = 0;
|
||||
|
|
|
|||
Loading…
Reference in a new issue