From ddd068491c9e8f7f77b6bba61269f867bdad204b Mon Sep 17 00:00:00 2001 From: wm4 Date: Sun, 16 Jul 2017 12:51:48 +0200 Subject: Replace remaining avcodec_close() calls This API isn't deprecated (yet?), but it's still inferior and harder to use than avcodec_free_context(). Leave the call only in 1 case in af_lavcac3enc.c, where we apparently seriously close and reopen the encoder for whatever reason. --- sub/sd_lavc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'sub') diff --git a/sub/sd_lavc.c b/sub/sd_lavc.c index 169a2883df..e805d5c34c 100644 --- a/sub/sd_lavc.c +++ b/sub/sd_lavc.c @@ -500,9 +500,7 @@ static void uninit(struct sd *sd) for (int n = 0; n < MAX_QUEUE; n++) clear_sub(&priv->subs[n]); - avcodec_close(priv->avctx); - av_free(priv->avctx->extradata); - av_free(priv->avctx); + avcodec_free_context(&priv->avctx); talloc_free(priv); } -- cgit v1.2.3