mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2026-10-28 10:04:37 +08:00
avformat/hlsenc: initialize avg_bandwidth
Fixes use of uninitialized value and dumping it into AVERAGE-BANDWIDTH in playlist. Note this will be correctly set when we are at final segment, otherwise it's optional. Fixes: fate-hls-seek test on MSAN build Signed-off-by: Kacper Michajłow <kasper93@gmail.com>
This commit is contained in:
1 parent
a02dfb1262
commit
dc953a19e6
1 file changed
+1
@@ -1472,6 +1472,7 @@ static int create_master_playlist(AVFormatContext *s,
|
||||
avg_bandwidth = vs->avg_bitrate;
|
||||
} else {
|
||||
bandwidth = 0;
|
||||
avg_bandwidth = 0;
|
||||
if (vid_st)
|
||||
bandwidth += get_stream_bit_rate(vid_st);
|
||||
if (aud_st)
|
||||
|
||||
Reference in new issue
Block a user