Skip to content

Commit ae1c403

Browse files
committed
Accept any <proto> value
1 parent 932dbd9 commit ae1c403

File tree

1 file changed

+0
-25
lines changed

1 file changed

+0
-25
lines changed

unmarshal.go

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -873,32 +873,7 @@ func unmarshalMediaDescription(lex *lexer) (stateFn, error) { //nolint:cyclop
873873
if err != nil {
874874
return nil, err
875875
}
876-
877-
// Set according to currently registered with IANA
878-
// https://tools.ietf.org/html/rfc4566#section-5.14
879-
// https://tools.ietf.org/html/rfc4975#section-8.1
880876
for _, proto := range strings.Split(field, "/") {
881-
if !anyOf(
882-
proto,
883-
"UDP",
884-
"RTP",
885-
"AVP",
886-
"SAVP",
887-
"SAVPF",
888-
"TLS",
889-
"DTLS",
890-
"SCTP",
891-
"AVPF",
892-
"TCP",
893-
"MSRP",
894-
"BFCP",
895-
"UDT",
896-
"IX",
897-
"MRCPv2",
898-
"FEC",
899-
) {
900-
return nil, fmt.Errorf("%w `%v`", errSDPInvalidNumericValue, field)
901-
}
902877
newMediaDesc.MediaName.Protos = append(newMediaDesc.MediaName.Protos, proto)
903878
}
904879

0 commit comments

Comments
 (0)