mirror of
https://git.videolan.org/git/ffmpeg.git
synced 2024-09-02 14:33:23 +02:00
avformat/mpegtsenc: Free services array completely on failure
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
12b59e57f3
commit
31eaecfee9
@ -778,7 +778,6 @@ static int mpegts_write_header(AVFormatContext *s)
|
||||
return 0;
|
||||
|
||||
fail:
|
||||
av_free(service);
|
||||
av_free(pids);
|
||||
for (i = 0; i < s->nb_streams; i++) {
|
||||
st = s->streams[i];
|
||||
@ -792,6 +791,14 @@ fail:
|
||||
}
|
||||
av_freep(&st->priv_data);
|
||||
}
|
||||
|
||||
for (i = 0; i < ts->nb_services; i++) {
|
||||
service = ts->services[i];
|
||||
av_freep(&service->provider_name);
|
||||
av_freep(&service->name);
|
||||
av_free(service);
|
||||
}
|
||||
av_free(ts->services);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user