Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle trailing semicolon on RTSP fmtp attribute #9247

Merged
merged 2 commits into from
Aug 4, 2021
Merged

Handle trailing semicolon on RTSP fmtp attribute #9247

merged 2 commits into from
Aug 4, 2021

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