mirror of
https://github.com/datarhei/core.git
synced 2025-09-26 20:11:29 +08:00
Fix 509 return code if non-existing stream is requested
This commit is contained in:
@@ -186,7 +186,7 @@ func (h *hls) handleEgress(c echo.Context, next echo.HandlerFunc) error {
|
||||
// Add the new session's top bitrate to the ingress top bitrate
|
||||
resultingBitrate := currentBitrate + streamBitrate
|
||||
|
||||
if resultingBitrate <= 0.5 || resultingBitrate >= maxBitrate {
|
||||
if resultingBitrate >= maxBitrate {
|
||||
return echo.NewHTTPError(509, "Bitrate limit exceeded")
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user