Andreas Rheinhardt bd131b64bc avformat/hlsenc: Fix leak of options when writing packets
Under certain circumstances hls_write_packet() would add options to an
AVDictionary. Said dictionary was never explicitly freed, instead it was
presumed that these options would be consumed when opening a new
IO-context. This left several possibilities for memleaks:

a) When no new IO-context would be opened at all. This is possible when
using both the flags temp_file and single_file together with a file
output.
b) When an error happens before one actually tries to open the new
IO-context.
c) When the new IO-context does not consume all options.

All three have been fixed; furthermore, the AVDictionary has been put
into a smaller scope (namely the only part of hls_write_packet() where
it is actually used).

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Reviewed-by: Steven Liu <lq@onvideo.cn>
2019-12-23 14:05:40 +08:00
..
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-11-29 19:58:35 +01:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-08-13 15:38:57 +02:00
2019-12-10 16:09:14 +01:00
2019-12-12 19:25:33 +01:00
2019-10-29 16:20:33 +01:00
2019-12-12 19:25:33 +01:00
2019-03-20 18:38:48 +01:00
2019-12-12 19:25:33 +01:00
2019-05-20 11:58:12 -07:00
2019-10-24 19:45:17 +02:00
2019-12-11 16:24:16 +01:00
2019-09-02 23:08:43 +02:00
2019-12-12 19:25:33 +01:00
2019-10-08 13:47:16 +08:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-05-20 11:58:12 -07:00
2019-09-27 12:15:50 +02:00
2019-12-12 19:25:33 +01:00
2019-09-02 23:08:43 +02:00
2019-11-27 23:54:20 +01:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-03-20 18:38:48 +01:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00
2019-10-08 13:46:42 +08:00
2019-06-14 21:36:39 +02:00
2019-12-12 19:25:33 +01:00
2019-12-12 19:25:33 +01:00