Skip to content

Commit

Permalink
prefer []*RtpHeaderExtension
Browse files Browse the repository at this point in the history
  • Loading branch information
jiyeyuran committed Oct 19, 2020
1 parent 0427da5 commit f7d8c0a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ortc.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ func validateRtcpFeedback(fb RtcpFeedback) error {
* Validates RtpHeaderExtension. It may modify given data by adding missing
* fields with default values.
*/
func validateRtpHeaderExtension(ext RtpHeaderExtension) (err error) {
func validateRtpHeaderExtension(ext *RtpHeaderExtension) (err error) {
if len(ext.Kind) > 0 && ext.Kind != MediaKind_Audio && ext.Kind != MediaKind_Video {
return NewTypeError("invalid ext.kind")
}
Expand Down
2 changes: 1 addition & 1 deletion rtp_parameters.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ type RtpCapabilities struct {
/**
* Supported RTP header extensions.
*/
HeaderExtensions []RtpHeaderExtension `json:"headerExtensions,omitempty"`
HeaderExtensions []*RtpHeaderExtension `json:"headerExtensions,omitempty"`

/**
* Supported FEC mechanisms.
Expand Down
2 changes: 1 addition & 1 deletion supported_rtp_capabilities.go
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ var supportedRtpCapabilities = RtpCapabilities{
},
},
},
HeaderExtensions: []RtpHeaderExtension{
HeaderExtensions: []*RtpHeaderExtension{
{
Kind: "audio",
Uri: "urn:ietf:params:rtp-hdrext:sdes:mid",
Expand Down

0 comments on commit f7d8c0a

Please sign in to comment.