From ab66c37ded8eb68abf7e0d8334f8e96228a2219b Mon Sep 17 00:00:00 2001 From: Ingo Oppermann Date: Mon, 12 Feb 2024 14:33:14 +0100 Subject: [PATCH] Fix emitting log message if a non-existing resource should be played --- srt/srt.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/srt/srt.go b/srt/srt.go index 18ad3870..69306b86 100644 --- a/srt/srt.go +++ b/srt/srt.go @@ -405,7 +405,12 @@ func (s *server) handleSubscribe(conn srt.Conn) { ch := s.channels[si.Resource] s.lock.RUnlock() - if ch == nil && s.proxy != nil { + if ch == nil { + if s.proxy == nil { + s.log(identity, "PLAY", "NOTFOUND", si.Resource, "no publisher for this resource found", client) + return + } + // Check in the cluster for the stream and proxy it srturl, err := s.proxy.GetURL("srt", si.Resource) if err != nil {