protocol/rtcp: fix case of protocols in comments

This commit is contained in:
Saxon 2019-04-16 16:31:04 +09:30
parent 9e55feafe7
commit 5cf39595eb
2 changed files with 5 additions and 4 deletions

View File

@ -21,7 +21,7 @@ const (
type log func(lvl int8, msg string, args ...interface{}) type log func(lvl int8, msg string, args ...interface{})
// client is an rtcp client that will hadle receiving SenderReports from a server // client is an RTCP client that will hadle receiving SenderReports from a server
// and sending out ReceiverReports. // and sending out ReceiverReports.
type client struct { type client struct {
ErrChan chan error ErrChan chan error
@ -88,7 +88,7 @@ func (c *client) Start() {
} }
// Stop sends a quit signal to the send and receive routines and closes the // Stop sends a quit signal to the send and receive routines and closes the
// udp connection. It will wait until both routines have returned. // UDP connection. It will wait until both routines have returned.
func (c *client) Stop() { func (c *client) Stop() {
c.log(logger.Debug, pkg+"client is stopping") c.log(logger.Debug, pkg+"client is stopping")
close(c.quitSend) close(c.quitSend)
@ -204,14 +204,14 @@ func (c *client) parse(buf []byte) {
} }
// UpdateSequence will allow updating of the highest sequence number received // UpdateSequence will allow updating of the highest sequence number received
// through an rtp stream. // through an RTP stream.
func (c *client) UpdateSequence(s uint32) { func (c *client) UpdateSequence(s uint32) {
c.mu.Lock() c.mu.Lock()
c.sequence = s c.sequence = s
c.mu.Unlock() c.mu.Unlock()
} }
// highestSequence will return the highest sequence number received through rtp. // highestSequence will return the highest sequence number received through RTP.
func (c *client) highestSequence() uint32 { func (c *client) highestSequence() uint32 {
var s uint32 var s uint32
c.mu.Lock() c.mu.Lock()

View File

@ -15,6 +15,7 @@ import (
// TestFromPayload checks that formPayload is working as expected. // TestFromPayload checks that formPayload is working as expected.
func TestFormPayload(t *testing.T) { func TestFormPayload(t *testing.T) {
// Expected data from a valid RTCP packet.
expect := []byte{ expect := []byte{
0x81, 0xc9, 0x00, 0x07, 0x81, 0xc9, 0x00, 0x07,
0xd6, 0xe0, 0x98, 0xda, 0xd6, 0xe0, 0x98, 0xda,