[Non-BE] Resolve "USAN: division by zero in DFt-Stereo DTX with frameloss"
- Related issues: #1010 (closed)
- Requested reviewers: @kiene
Reason why this change is needed
- The Stereo CNG decoder may trigger a division-by-zero.
Description of the change
- The IPD and ITD crossfade is supposed to halt when the respective target ITD and IPD are reached. This check was however done using a comparison between the actual and target value. With rounding errors, this value may be overshot, resulting in an additional crossfade step and a division-by-zero. The check is changed to be done on the integer counter instead, such that the crossfade is only done when the counter is strictly less than the maximum number of crossfade steps.
Affected operating points
- Stereo CNG decoding
Related to #1010 (closed)