avcodec/aacpsy: Clear the correct pointer
authorMichael Niedermayer <michaelni@gmx.at>
Sun, 31 May 2015 23:32:24 +0000 (01:32 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Sun, 31 May 2015 23:32:24 +0000 (01:32 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/aacpsy.c

index 0d05937..3a66159 100644 (file)
@@ -358,7 +358,7 @@ static av_cold int psy_3gpp_init(FFPsyContext *ctx) {
 
     pctx->ch = av_mallocz_array(ctx->avctx->channels, sizeof(AacPsyChannel));
     if (!pctx->ch) {
-        av_freep(&pctx);
+        av_freep(&ctx->model_priv_data);
         return AVERROR(ENOMEM);
     }