Re: [FFmpeg-devel] [PATCH] gifdec: use truncated width for image manipulation

2014-08-18 Thread Michael Niedermayer
On Mon, Aug 18, 2014 at 09:42:08AM +0200, Christophe Gisquet wrote: > Hi, > > 2014-08-17 23:53 GMT+02:00 Michael Niedermayer : > >> > i think these need a check for top >= s->screen_height and > >> > left >= s->screen_width > [...] > > 0x007319ea in gif_fill_rect (picture=0x1a96a60, color=

Re: [FFmpeg-devel] [PATCH] gifdec: use truncated width for image manipulation

2014-08-18 Thread Christophe Gisquet
Hi, 2014-08-17 23:53 GMT+02:00 Michael Niedermayer : >> > i think these need a check for top >= s->screen_height and >> > left >= s->screen_width [...] > 0x007319ea in gif_fill_rect (picture=0x1a96a60, color=16777215, l=0, > t=65535, w=192, h=-65367) at libavcodec/gifdec.c:108 Sorry for

Re: [FFmpeg-devel] [PATCH] gifdec: use truncated width for image manipulation

2014-08-17 Thread Michael Niedermayer
On Sun, Aug 17, 2014 at 09:47:25PM +0200, Christophe Gisquet wrote: > Hi, > > 2014-08-17 20:39 GMT+02:00 Michael Niedermayer : > >> +if (width > s->screen_width) { > >> +av_log(s->avctx, AV_LOG_ERROR, "Invalid image width.\n"); > >> +return AVERROR_INVALIDDATA; > >> +} > >>

Re: [FFmpeg-devel] [PATCH] gifdec: use truncated width for image manipulation

2014-08-17 Thread Christophe Gisquet
Hi, 2014-08-17 20:39 GMT+02:00 Michael Niedermayer : >> +if (width > s->screen_width) { >> +av_log(s->avctx, AV_LOG_ERROR, "Invalid image width.\n"); >> +return AVERROR_INVALIDDATA; >> +} >> +if (left + width > s->screen_width) { >> +/* width must be kept around

Re: [FFmpeg-devel] [PATCH] gifdec: use truncated width for image manipulation

2014-08-17 Thread Michael Niedermayer
On Sun, Aug 17, 2014 at 10:41:53AM +0200, Christophe Gisquet wrote: > Hi, > > the attached patch fixes ticket #3538, which is an off-by-one error. > Unfortunately, I see no way of detecting it as a "correctable" > behavior and not an actual error besides that. > > Maybe restricting this to actual

[FFmpeg-devel] [PATCH] gifdec: use truncated width for image manipulation

2014-08-17 Thread Christophe Gisquet
Hi, the attached patch fixes ticket #3538, which is an off-by-one error. Unfortunately, I see no way of detecting it as a "correctable" behavior and not an actual error besides that. Maybe restricting this to actual off-by-one errors would be better, too. -- Christophe From 59ea1d72b27272d2a28c