Edge: Fix inverted check that blocked HTTP-FLV play.

SrsHttpStreamServer::assemble() registered the dynamic matcher only
when the mux cast was NULL, so the matcher was never wired up. On an
edge the FLV mount is created lazily via the dynamic matcher when a
client requests it, so HTTP-FLV play on edge always returned 404.
Invert the guard so the matcher is registered when the mux is valid,
mirroring the destructor.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
winlin 2026-05-19 07:41:05 -04:00
parent 913b773282
commit eb9141e450

View File

@ -1076,7 +1076,7 @@ SrsHttpStreamServer::SrsHttpStreamServer()
void SrsHttpStreamServer::assemble()
{
SrsHttpServeMux *mux = dynamic_cast<SrsHttpServeMux *>(mux_);
if (!mux) {
if (mux) {
mux->add_dynamic_matcher(this);
}
}