On Wed, Nov 01, 2017 at 09:39:52PM +0100, Nicolas George wrote: > For now, check the image size. > Inspired by a patch from Paul B Mahol. > > Invalid sizes would be detected later by allocation failures, > detecting problems earlier is cleaner. > > Signed-off-by: Nicolas George <geo...@nsup.org> > --- > libavfilter/avfiltergraph.c | 24 ++++++++++++++++++++++++ > 1 file changed, 24 insertions(+) > > diff --git a/libavfilter/avfiltergraph.c b/libavfilter/avfiltergraph.c > index 69cf26896d..a009e0a760 100644 > --- a/libavfilter/avfiltergraph.c > +++ b/libavfilter/avfiltergraph.c > @@ -28,6 +28,7 @@ > #include "libavutil/avstring.h" > #include "libavutil/bprint.h" > #include "libavutil/channel_layout.h" > +#include "libavutil/imgutils.h" > #include "libavutil/internal.h" > #include "libavutil/opt.h" > #include "libavutil/pixdesc.h" > @@ -263,6 +264,27 @@ static int graph_config_links(AVFilterGraph *graph, > AVClass *log_ctx) > return 0; > } > > +static int graph_check_links(AVFilterGraph *graph, AVClass *log_ctx) > +{ > + AVFilterContext *f; > + AVFilterLink *l;
> + unsigned i, j; nb_filters and nb_outputs are signed so the counters better be the same type. I think we already had that discussion but I'd rather have the counters signed so the compiler can exploit the undefined property of signed overflow to assume it will never happen. [...] -- Clément B.
signature.asc
Description: PGP signature
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel