avcodec/diracdec: Make data_unit_size unsigned

Fixes CID1271788

with this change the value is more explicitly checked, it was fully checked
before though

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2015-05-14 23:16:06 +02:00
parent a9bf628bfd
commit 8f1afde11d

View File

@ -1933,8 +1933,9 @@ static int dirac_decode_frame(AVCodecContext *avctx, void *data, int *got_frame,
AVFrame *picture = data; AVFrame *picture = data;
uint8_t *buf = pkt->data; uint8_t *buf = pkt->data;
int buf_size = pkt->size; int buf_size = pkt->size;
int i, data_unit_size, buf_idx = 0; int i, buf_idx = 0;
int ret; int ret;
unsigned data_unit_size;
/* release unused frames */ /* release unused frames */
for (i = 0; i < MAX_FRAMES; i++) for (i = 0; i < MAX_FRAMES; i++)