diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c index f46e8d4a53..a76dbce6e1 100644 --- a/libavformat/hlsenc.c +++ b/libavformat/hlsenc.c @@ -486,7 +486,7 @@ static int hls_write_trailer(struct AVFormatContext *s) hls_free_segments(hls->segments); hls_free_segments(hls->old_segments); - avio_close(hls->pb); + avio_closep(&hls->pb); return 0; }