hls: fix leaking avio_opts on hls_read_header error

Use the hls_close function to reduce code duplication.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
This commit is contained in:
Andreas Cadhalpun 2016-11-07 19:43:16 +01:00
parent a305e0e5c0
commit 2c90316b46

View File

@ -1807,9 +1807,7 @@ static int hls_read_header(AVFormatContext *s)
return 0;
fail:
free_playlist_list(c);
free_variant_list(c);
free_rendition_list(c);
hls_close(s);
return ret;
}