[FFmpeg-devel] [PATCH] Per-frame metadata

Stefano Sabatini stefano.sabatini-lala at poste.it
Wed Apr 13 13:32:32 CEST 2011


On date Wednesday 2011-04-13 13:07:44 +0200, Nicolas George encoded:
> Le tridi 23 germinal, an CCXIX, Stefano Sabatini a écrit :
> > In many cases we propagate the error code, not having to remap it is a
> > bonus.
> 
> I do not really see the bonus between
> 
> 	if (av_size_mult(siezof(foo, n, &size) < 0)
> 	    return AVERROR(EINVAL);
> 
> and
> 
> 	r = av_size_mult(siezof(foo, n, &size);
> 	if (r < 0)
> 	    return r;

But:

if ((ret = ...             )<0) goto fail;
...
if ((ret = av_size_mult(...)<0) goto fail;
...
fail:
    ...
    return ret;
 
> The only benefit I see is in term of API uniformity, thus the question:
> Do you think this is worth making mem.h depend on error.h?

Isn't it already included? (mem.h includes avutil.h which includes
error.h).
-- 
FFmpeg = Furious and Furious Mortal Pure Easy God


More information about the ffmpeg-devel mailing list