mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-05-13 21:26:33 +02:00
avformat/sapenc: Use avio_closep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
2959a61232
commit
643dee846a
@ -49,7 +49,7 @@ static int sap_write_close(AVFormatContext *s)
|
|||||||
if (!rtpctx)
|
if (!rtpctx)
|
||||||
continue;
|
continue;
|
||||||
av_write_trailer(rtpctx);
|
av_write_trailer(rtpctx);
|
||||||
avio_close(rtpctx->pb);
|
avio_closep(&rtpctx->pb);
|
||||||
avformat_free_context(rtpctx);
|
avformat_free_context(rtpctx);
|
||||||
s->streams[i]->priv_data = NULL;
|
s->streams[i]->priv_data = NULL;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user