Skip to content

Refactor RTSPClient regex handling for hostname extraction#1676

Open
paulomorgado wants to merge 1 commit into
sipsorcery-org:masterfrom
paulomorgado:regex-2
Open

Refactor RTSPClient regex handling for hostname extraction#1676
paulomorgado wants to merge 1 commit into
sipsorcery-org:masterfrom
paulomorgado:regex-2

Conversation

@paulomorgado
Copy link
Copy Markdown
Contributor

Refactored RTSPClient to use a shared regex pattern for extracting hostnames from RTSP URLs. Introduced conditional compilation: .NET 7+ uses [GeneratedRegex] for performance, while earlier versions use static Regex fields. Updated GetStreamDescription and Start methods to use the new regex approach. Changed RTSPClient to a partial class.

Refactored RTSPClient to use a shared regex pattern for extracting hostnames from RTSP URLs. Introduced conditional compilation: .NET 7+ uses [GeneratedRegex] for performance, while earlier versions use static Regex fields. Updated GetStreamDescription and Start methods to use the new regex approach. Changed RTSPClient to a partial class.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant