mirror of
https://github.com/aler9/gortsplib
synced 2025-10-09 17:10:06 +08:00
unexport ConnClient.WriteFrame
This commit is contained in:
@@ -234,8 +234,9 @@ func (c *ConnClient) Do(req *Request) (*Response, error) {
|
|||||||
return res, nil
|
return res, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// WriteFrame writes an InterleavedFrame.
|
// this can't be exported
|
||||||
func (c *ConnClient) WriteFrame(frame *InterleavedFrame) error {
|
// otherwise there's a race condition with the rtcp receiver report routine
|
||||||
|
func (c *ConnClient) writeFrame(frame *InterleavedFrame) error {
|
||||||
c.nconn.SetWriteDeadline(time.Now().Add(c.conf.WriteTimeout))
|
c.nconn.SetWriteDeadline(time.Now().Add(c.conf.WriteTimeout))
|
||||||
return frame.Write(c.bw)
|
return frame.Write(c.bw)
|
||||||
}
|
}
|
||||||
@@ -603,7 +604,7 @@ func (c *ConnClient) Play(u *url.URL) (*Response, error) {
|
|||||||
})
|
})
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
c.WriteFrame(&InterleavedFrame{
|
c.writeFrame(&InterleavedFrame{
|
||||||
TrackId: trackId,
|
TrackId: trackId,
|
||||||
StreamType: StreamTypeRtcp,
|
StreamType: StreamTypeRtcp,
|
||||||
Content: frame,
|
Content: frame,
|
||||||
|
Reference in New Issue
Block a user