Commit 1cb8978e authored by Jean-Paul Saman's avatar Jean-Paul Saman
Browse files

stream_filter/httplive.c: newstream can also be 0 (first index in vlc_array_t).

HTTP Live Streams are number from 0 in vlc_array_t. The condition in Download()
excluded 0 as valid stream. The first element in the array is at index 0, so consider
this to be valid.
(cherry picked from commit 7acbd2448c289cf28a80cfc0dd2ece21860aa6e9)
parent 6ab6ab61
......@@ -852,7 +852,7 @@ static int Download(stream_t *s, hls_stream_t *hls, segment_t *segment, int *cur
if (hls->bandwidth != bw)
int newstream = BandwidthAdaptation(s, hls->id, &bw);
if ((newstream > 0) && (newstream != *cur_stream))
if ((newstream >= 0) && (newstream != *cur_stream))
msg_Info(s, "switching to %s bandwidth (%"PRIu64") stream",
(hls->bandwidth <= bw) ? "faster" : "lower", bw);
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