Skip to content

Change ATTRIBUTE_PATTERN in SessionDescriptionParser #9430

Closed
@nibblis

Description

@nibblis

Can you change SessionDescriptionParser?

I would like to change:
ATTRIBUTE_PATTERN = Pattern.compile("([0-9A-Za-z-]+)(?::(.*))?");
to
ATTRIBUTE_PATTERN = Pattern.compile("([0-9A-Za-z-_]+)(?::(.*))?");
add _

The problem is that my camera's response contains the line a=Media_header:MEDIAINFO=494D4B48010100000400010000000000000000000000000000000000000000000000000000000000; and an exception is thrown:

Caused by: com.google.android.exoplayer2.ParserException: Malformed Attribute line: a=Media_header:MEDIAINFO=494D4B48010100000400010000000000000000000000000000000000000000000000000000000000;
at com.google.android.exoplayer2.source.rtsp.SessionDescriptionParser.parse(SessionDescriptionParser.java:159)
at com.google.android.exoplayer2.source.rtsp.RtspClient$MessageListener.handleRtspMessage(RtspClient.java:476)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions