Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions internal/protocols/mpegts/from_stream.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,8 @@ func FromStream(

dts, err := dtsExtractor.Extract(u.Payload.(unit.PayloadH265), u.PTS)
if err != nil {
return err
dtsExtractor = nil
return nil
}

sconn.SetWriteDeadline(time.Now().Add(writeTimeout))
Expand Down Expand Up @@ -120,7 +121,8 @@ func FromStream(

dts, err := dtsExtractor.Extract(u.Payload.(unit.PayloadH264), u.PTS)
if err != nil {
return err
dtsExtractor = nil
return nil
}

sconn.SetWriteDeadline(time.Now().Add(writeTimeout))
Expand Down
6 changes: 4 additions & 2 deletions internal/protocols/rtmp/from_stream.go
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,8 @@ func FromStream(

dts, err := videoDTSExtractor.Extract(u.Payload.(unit.PayloadH265), u.PTS)
if err != nil {
return err
videoDTSExtractor = nil
return nil
}

nconn.SetWriteDeadline(time.Now().Add(writeTimeout))
Expand Down Expand Up @@ -203,7 +204,8 @@ func FromStream(

dts, err := videoDTSExtractor.Extract(u.Payload.(unit.PayloadH264), u.PTS)
if err != nil {
return err
videoDTSExtractor = nil
return nil
}

nconn.SetWriteDeadline(time.Now().Add(writeTimeout))
Expand Down
6 changes: 4 additions & 2 deletions internal/recorder/format_fmp4.go
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,8 @@ func (f *formatFMP4) initialize() bool {

dts, err := dtsExtractor.Extract(u.Payload.(unit.PayloadH265), u.PTS)
if err != nil {
return err
dtsExtractor = nil
return nil
}

var sampl fmp4.Sample
Expand Down Expand Up @@ -475,7 +476,8 @@ func (f *formatFMP4) initialize() bool {

dts, err := dtsExtractor.Extract(u.Payload.(unit.PayloadH264), u.PTS)
if err != nil {
return err
dtsExtractor = nil
return nil
}

var sampl fmp4.Sample
Expand Down
6 changes: 4 additions & 2 deletions internal/recorder/format_mpegts.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,8 @@ func (f *formatMPEGTS) initialize() bool {

dts, err := dtsExtractor.Extract(u.Payload.(unit.PayloadH265), u.PTS)
if err != nil {
return err
dtsExtractor = nil
return nil
}

return track.write(
Expand Down Expand Up @@ -151,7 +152,8 @@ func (f *formatMPEGTS) initialize() bool {

dts, err := dtsExtractor.Extract(u.Payload.(unit.PayloadH264), u.PTS)
if err != nil {
return err
dtsExtractor = nil
return nil
}

return track.write(
Expand Down