On 11 February 2015 at 18:03, Diego Biurrun <[email protected]> wrote:
> On Wed, Feb 11, 2015 at 03:05:23AM +0530, Himangi Saraogi wrote:
> > ---
> > libavcodec/vp56.c | 15 ++++++++-------
> > 1 file changed, 8 insertions(+), 7 deletions(-)
>
> There is a stray ".patch" in your log message.
>
> > --- a/libavcodec/vp56.c
> > +++ b/libavcodec/vp56.c
> > @@ -530,20 +530,21 @@ int ff_vp56_decode_frame(AVCodecContext *avctx,
> void *data, int *got_frame,
> > av_frame_unref(s->frames[i]);
> > if (is_alpha) {
> > ff_set_dimensions(avctx, 0, 0);
> > - return -1;
> > + return AVERROR_INVALIDDATA;
> > }
> > }
> >
> > if (!is_alpha) {
> > - if (ff_get_buffer(avctx, p, AV_GET_BUFFER_FLAG_REF) < 0) {
> > + int ret = ff_get_buffer(avctx, p, AV_GET_BUFFER_FLAG_REF);
> > + if (ret < 0) {
> > av_log(avctx, AV_LOG_ERROR, "get_buffer() failed\n");
> > - return -1;
> > + return ret;
> > }
> >
> > if (res == VP56_SIZE_CHANGE)
> > if (vp56_size_changed(avctx)) {
> > av_frame_unref(p);
> > - return -1;
> > + return AVERROR_INVALIDDATA;
> > }
> > }
>
> All of these functions return error codes, just propagate them.
> Forwarding error codes is always better than making up your own.
>
>
Not quite sure how that can be done here as the errors are not really on
return values.
-Himangi
> Diego
> _______________________________________________
> libav-devel mailing list
> [email protected]
> https://lists.libav.org/mailman/listinfo/libav-devel
>
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel