Commit de63839e authored by Francois Cartegnie's avatar Francois Cartegnie Committed by Jean-Baptiste Kempf

stream_filter: httplive: don't trust stream size

(cherry picked from commit a13829b11afe1b56d5ecec4afa0b62b44af10739)
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent 9d161343
...@@ -1881,7 +1881,8 @@ static int hls_Download(stream_t *s, segment_t *segment) ...@@ -1881,7 +1881,8 @@ static int hls_Download(stream_t *s, segment_t *segment)
} }
int i_canc = vlc_savecancel(); int i_canc = vlc_savecancel();
int i_length = stream_Read(p_ts, &p_segment_data->p_buffer[i_total_read], HLS_READ_SIZE); int i_length = stream_Read(p_ts, &p_segment_data->p_buffer[i_total_read],
(i_toread >= HLS_READ_SIZE) ? HLS_READ_SIZE : i_toread);
vlc_restorecancel(i_canc); vlc_restorecancel(i_canc);
if (i_length <= 0) if (i_length <= 0)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment