X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Fopusdec.c;h=95a2435e539f0c807bc2b5b21a92e77d12c0071f;hb=a240aefc7a2591f7b307e2910df655801ae6ca44;hp=31871e99941881571ceb48b33d754f3778dc1381;hpb=87a6f532b46fb16eea07943325f5d322d08e13ed;p=ffmpeg diff --git a/libavcodec/opusdec.c b/libavcodec/opusdec.c index 31871e99941..95a2435e539 100644 --- a/libavcodec/opusdec.c +++ b/libavcodec/opusdec.c @@ -671,8 +671,11 @@ static av_cold int opus_decode_init(AVCodecContext *avctx) /* find out the channel configuration */ ret = ff_opus_parse_extradata(avctx, c); - if (ret < 0) + if (ret < 0) { + av_freep(&c->channel_maps); + av_freep(&c->fdsp); return ret; + } /* allocate and init each independent decoder */ c->streams = av_mallocz_array(c->nb_streams, sizeof(*c->streams));