[FFmpeg-devel] [PATCH] avutil/mem: set default allocation limit to "unlimited"

wm4 nfxjfg at googlemail.com
Tue Mar 31 18:41:12 CEST 2015


On Tue, 31 Mar 2015 15:53:36 +0000 (UTC)
Carl Eugen Hoyos <cehoyos at ag.or.at> wrote:

> Michael Niedermayer <michaelni <at> gmx.at> writes:
> 
> > -static size_t max_alloc_size= INT_MAX;
> > +static size_t max_alloc_size= SIZE_MAX;
> 
> What would this fix?

Nothing yet, because both AVPacket and AVFrame still use ints for size
quantities.

> I remember several reports about FFmpeg "leaking" 
> memory where the users just meant that one of 
> the libraries allocated more memory than the 
> user meant is sane, sometimes even using the 
> magical signs "DOS".
> I don't remember a report about 16kx16k being 
> too small...

The 16kx16kx is a separate limitation in av_image_check_size(). (And
yes I know someone who tried to read highres images with ffmpeg, and it
failed because of this.)

> (I really don't care and certainly don't object)
> 


More information about the ffmpeg-devel mailing list