Fix a crash when trying to get HLS fragments from a disconnected strema.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 13 Oct 2019 21:14:04 +0000 (23:14 +0200)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 13 Oct 2019 21:14:04 +0000 (23:14 +0200)
commit7ec54788f88dde7b083ba6cfd30732b32295b54a
treef6c4a46f043233b93901af272f9687377c83ea77
parent980ac162414c9fce62af4fdb9cfc282865b31572
Fix a crash when trying to get HLS fragments from a disconnected strema.

After the last patch, we would try to serve HLS fragments even if the
backend is down, but we had zeroed out the HTTP header, causing an
assertion failure with HTTP/1.1 clients (and an invalid HTTP response
for HTTP/1.0 clients). Fix by keeping the header and setting a special
“unavailable” flag instead (which allows us to keep sending HLS fragments).
httpinput.cpp
server.cpp
server.h
serverpool.cpp
serverpool.h
state.proto
stream.cpp
stream.h