Fix SDP parsing for repeat time field with no offsets (#880)

Co-authored-by: Nicolas BRAINEZ <nicolas.brainez@ext.ec.europa.eu>
This commit is contained in:
nicoske
2025-09-05 23:04:30 +02:00
committed by GitHub
parent a8513af402
commit 1bc89661eb
2 changed files with 52 additions and 1 deletions

View File

@@ -393,7 +393,7 @@ func parseTimeUnits(value string) (int64, error) {
func (s *SessionDescription) unmarshalRepeatTimes(value string) error {
fields := strings.Fields(value)
if len(fields) < 3 {
if len(fields) < 2 {
return fmt.Errorf("%w `r=%v`", errSDPInvalidSyntax, value)
}