summaryrefslogtreecommitdiff
path: root/libavfilter/vf_hwdownload.c
diff options
context:
space:
mode:
authordsmudhar <ds.mudhar@gmail.com>2016-05-22 06:26:36 +0530
committerMichael Niedermayer <michael@niedermayer.cc>2016-05-24 20:00:17 +0200
commit04d35004c3d050c0bede909e4d1b30f0dc379cfa (patch)
tree132a42e877c9fb8232a445849db1b8d9c7443a4c /libavfilter/vf_hwdownload.c
parent35b37591c0345abfd35b0cfcaed3b35fba5512a8 (diff)
libavfilter/vf_hwdownload: show error when ff_formats_ref fails
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavfilter/vf_hwdownload.c')
-rw-r--r--libavfilter/vf_hwdownload.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libavfilter/vf_hwdownload.c b/libavfilter/vf_hwdownload.c
index 2dcc9fa059..79ea82d4ec 100644
--- a/libavfilter/vf_hwdownload.c
+++ b/libavfilter/vf_hwdownload.c
@@ -56,8 +56,10 @@ static int hwdownload_query_formats(AVFilterContext *avctx)
}
}
- ff_formats_ref(infmts, &avctx->inputs[0]->out_formats);
- ff_formats_ref(outfmts, &avctx->outputs[0]->in_formats);
+ if ((err = ff_formats_ref(infmts, &avctx->inputs[0]->out_formats)) < 0 ||
+ (err = ff_formats_ref(outfmts, &avctx->outputs[0]->in_formats)) < 0)
+ return err;
+
return 0;
}