From 26d94558beba21a384ce6f0f69d9c447e76c605b Mon Sep 17 00:00:00 2001 From: Sergey Petrov Date: Tue, 22 Apr 2025 16:38:38 +0500 Subject: [PATCH] Added ignoring "lost package error". --- writer/internal/ingest/rtsp/rtsp.go | 36 +++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/writer/internal/ingest/rtsp/rtsp.go b/writer/internal/ingest/rtsp/rtsp.go index 62a20c2..0f5fec5 100644 --- a/writer/internal/ingest/rtsp/rtsp.go +++ b/writer/internal/ingest/rtsp/rtsp.go @@ -254,6 +254,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -349,6 +352,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -474,6 +480,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -687,6 +696,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -832,6 +844,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -942,6 +957,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -1030,6 +1048,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -1118,6 +1139,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -1208,6 +1232,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -1296,6 +1323,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -1393,6 +1423,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method { @@ -1490,6 +1523,9 @@ func rtsp(dir string, period int, link string, number int) error { return err } + // Skip "lost packet error". + c.OnPacketsLost = func(lost uint64) {} + // Set program if the client gets request. c.OnRequest = func(req *base.Request) { switch req.Method {