build: Fix warning under modern GCC.

The mpglib library had some fun code to clear
out the remainder of an array. This tripped
up the array bounds check.

This change makes the code just go through the
array until it reaches the end, instead.

ASTERISK-29687
ASTERISK-29712

Change-Id: Ib4f636409fe58d31ead3bd3f958cd74c087b892d
This commit is contained in:
Joshua C. Colp 2022-03-29 12:22:17 -03:00
parent 03d86c640c
commit 292540b472

View file

@ -948,8 +948,7 @@ static int III_dequantize_sample(struct mpstr *mp, real xr[SBLIMIT][SSLIMIT],int
/* /*
* zero part * zero part
*/ */
for(i=(&xr[SBLIMIT][0]-xrpnt)>>1;i;i--) { while (xrpnt <= &xr[SBLIMIT-1][SSLIMIT-1]) {
*xrpnt++ = 0.0;
*xrpnt++ = 0.0; *xrpnt++ = 0.0;
} }