1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

avformat/amvenc: Remove unnecessary av_packet_free()

The muxer's deinit function takes care of cleaning up when init fails.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
This commit is contained in:
Andreas Rheinhardt 2021-03-18 06:29:35 +01:00
parent 3903c139a9
commit dfad5794fb

View File

@ -187,7 +187,6 @@ static av_cold int amv_init(AVFormatContext *s)
if (!amv->apad)
return AVERROR(ENOMEM);
if ((ret = av_new_packet(amv->apad, amv->ablock_align)) < 0) {
av_packet_free(&amv->apad);
return ret;
}
@ -197,7 +196,6 @@ static av_cold int amv_init(AVFormatContext *s)
amv->vpad = av_packet_alloc();
if (!amv->vpad) {
av_packet_free(&amv->apad);
return AVERROR(ENOMEM);
}
amv->vpad->stream_index = AMV_STREAM_VIDEO;