aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2013-11-01 15:26:38 +0000
committerPaul B Mahol <onemda@gmail.com>2013-11-01 19:05:35 +0000
commit01507ab3699222f5a1be58625e916c173f1be0da (patch)
tree0b040eef0963df4608047d85291630f8016dceb8
parent73d887733dc2ccb5d570615a753d5c44c3f1d9a4 (diff)
downloadffmpeg-01507ab3699222f5a1be58625e916c173f1be0da.tar.gz
avcodec/sanm: stop using deprecated avcodec_set_dimensions()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
-rw-r--r--libavcodec/sanm.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/libavcodec/sanm.c b/libavcodec/sanm.c
index 76da8bbe9c..a6c1c01e5c 100644
--- a/libavcodec/sanm.c
+++ b/libavcodec/sanm.c
@@ -738,11 +738,10 @@ static int process_frame_obj(SANMVideoContext *ctx)
}
if (ctx->width < left + w || ctx->height < top + h) {
- if (av_image_check_size(FFMAX(left + w, ctx->width),
- FFMAX(top + h, ctx->height), 0, ctx->avctx) < 0)
- return AVERROR_INVALIDDATA;
- avcodec_set_dimensions(ctx->avctx, FFMAX(left + w, ctx->width),
- FFMAX(top + h, ctx->height));
+ int ret = ff_set_dimensions(ctx->avctx, FFMAX(left + w, ctx->width),
+ FFMAX(top + h, ctx->height));
+ if (ret < 0)
+ return ret;
init_sizes(ctx, FFMAX(left + w, ctx->width),
FFMAX(top + h, ctx->height));
if (init_buffers(ctx)) {