New submission from Kent Mein <[email protected]>:
This is coverity CID: 442
Checker: OVERRUN_STATIC (help)
File: base/src/extern/ffmpeg/libavcodec/dsputil.c
Function: dsputil_init
Description: Overrun of static array "(c)->put_2tap_qpel_pixels_tab[0]" of size
16 at position 63 with index variable "i"
4664 for(i=0; i<64; i++){
4665 if(!c->put_2tap_qpel_pixels_tab[0][i])
4666 c->put_2tap_qpel_pixels_tab[0][i]=
c->put_h264_qpel_pixels_tab[0][i];
4667 if(!c->avg_2tap_qpel_pixels_tab[0][i])
4668 c->avg_2tap_qpel_pixels_tab[0][i]=
c->avg_h264_qpel_pixels_tab[0][i];
4669 }
looking at disputil.h you can see that those two arrays are only size
16. I would change the for loop and remove the elses...
If there is something I'm missing where this is defined somewhere else.
I would make a variable PIXELS_TAB_SIZE or something and use that as the bounds
for the loop instead of the way it is now.
(accessing beyond an array is undefined so not safe)
Last report for today I promise ;)
----------
messages: 6755
priority: normal
status: new
substatus: new
title: another overrun of static array.
type: bug
_____________________________________________________
FFmpeg issue tracker <[email protected]>
<https://roundup.ffmpeg.org/roundup/ffmpeg/issue1341>
_____________________________________________________