diff --git a/src/output/output_hls.cpp b/src/output/output_hls.cpp index 19d083e6..ad810aa7 100644 --- a/src/output/output_hls.cpp +++ b/src/output/output_hls.cpp @@ -232,6 +232,7 @@ namespace Mist{ H.setCORSHeaders(); if (H.method == "OPTIONS" || H.method == "HEAD"){ H.SendResponse("200", "OK", myConn); + responded = true; return; } H.SetBody(""); H.SendResponse("200", "OK", myConn); + responded = true; return; }// crossdomain.xml @@ -262,6 +264,7 @@ namespace Mist{ } H.SetBody(""); H.SendResponse("200", "OK", myConn); + responded = true; return; } @@ -311,6 +314,7 @@ namespace Mist{ targetTime = HLS::getPartTargetTime(M, idx, mTrack, startTime, msn, part); if (!targetTime){ H.SendResponse("404", "Partial fragment does not exist", myConn); + responded = true; return; } startTime += part * HLS::partDurationMaxMs; @@ -372,6 +376,7 @@ namespace Mist{ "served.\n"); myConn.SendNow(H.BuildResponse("404", "Fragment out of range")); WARN_MSG("Fragment @ %" PRIu64 " too old", startTime); + responded = true; return; } @@ -389,10 +394,12 @@ namespace Mist{ } if (H.method == "OPTIONS" || H.method == "HEAD"){ H.SendResponse("200", "OK", myConn); + responded = true; return; } H.StartResponse(H, myConn, VLCworkaround || config->getBool("nonchunked")); + responded = true; // we assume whole fragments - but timestamps may be altered at will contPAT = fragmentIndex; // PAT continuity counter contPMT = fragmentIndex; // PMT continuity counter @@ -419,6 +426,7 @@ namespace Mist{ // Strip /hls// from url std::string url = H.url.substr(H.url.find('/', 5) + 1); sendHlsManifest(url); + responded = true; } }