Skip to content

Handle trailing semicolon on RTSP fmtp attribute#9247

Merged
christosts merged 2 commits intogoogle:dev-v2from
colinbarr:dev-v2-rtsp-fmtp-trailing-semicolon
Aug 4, 2021
Merged

Handle trailing semicolon on RTSP fmtp attribute#9247
christosts merged 2 commits intogoogle:dev-v2from
colinbarr:dev-v2-rtsp-fmtp-trailing-semicolon

Conversation

@colinbarr
Copy link
Contributor

As documented here, an ArrayIndexOutOfBoundsException occurs if an a=fmtp line from an RTSP SDP response ends with a trailing semicolon. This change switches from using a limit of -1 on the String split(...) function via the Util class when parsing fmtp parameters, to using the implicit limit of 0. As a result, empty trailing strings are discarded which avoids this error condition.

Fixes #9114

@colinbarr colinbarr requested a review from claincly August 3, 2021 09:34
Copy link
Contributor

@claincly claincly left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@christosts christosts merged commit 81d0fe2 into google:dev-v2 Aug 4, 2021
christosts added a commit that referenced this pull request Aug 11, 2021
@google google locked and limited conversation to collaborators Oct 4, 2021
@colinbarr colinbarr deleted the dev-v2-rtsp-fmtp-trailing-semicolon branch March 28, 2023 00:10
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants