diff options
| author | David Ullmer <daullmer@gmail.com> | 2021-02-11 13:48:58 +0100 |
|---|---|---|
| committer | David Ullmer <daullmer@gmail.com> | 2021-02-11 13:48:58 +0100 |
| commit | ab5fb1b1f201795041a960c74b540c768fe8d08b (patch) | |
| tree | 579964cea4db7e04299084d555e493b9dc74ca54 /MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs | |
| parent | ae57ed4ac70eda1046c86e40e41b9683b2115f59 (diff) | |
| parent | d490c1c2bcb2852c9159e8578bc7a60e086e4202 (diff) | |
Merge branch 'master' of github.com:jellyfin/jellyfin into nfo-watched
Diffstat (limited to 'MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs')
| -rw-r--r-- | MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs b/MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs index 4a87f87dc..ccef7eeea 100644 --- a/MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs +++ b/MediaBrowser.MediaEncoding/Subtitles/SrtParser.cs @@ -79,7 +79,7 @@ namespace MediaBrowser.MediaEncoding.Subtitles subEvent.Text = string.Join(ParserValues.NewLine, multiline); subEvent.Text = subEvent.Text.Replace(@"\N", ParserValues.NewLine, StringComparison.OrdinalIgnoreCase); - subEvent.Text = Regex.Replace(subEvent.Text, @"\{(?:\\\d?[\w.-]+(?:\([^\)]*\)|&H?[0-9A-Fa-f]+&|))+\}", string.Empty, RegexOptions.IgnoreCase); + subEvent.Text = Regex.Replace(subEvent.Text, @"\{(?:\\[0-9]?[\w.-]+(?:\([^\)]*\)|&H?[0-9A-Fa-f]+&|))+\}", string.Empty, RegexOptions.IgnoreCase); subEvent.Text = Regex.Replace(subEvent.Text, "<", "<", RegexOptions.IgnoreCase); subEvent.Text = Regex.Replace(subEvent.Text, ">", ">", RegexOptions.IgnoreCase); subEvent.Text = Regex.Replace(subEvent.Text, "<(\\/?(font|b|u|i|s))((\\s+(\\w|\\w[\\w\\-]*\\w)(\\s*=\\s*(?:\\\".*?\\\"|'.*?'|[^'\\\">\\s]+))?)+\\s*|\\s*)(\\/?)>", "<$1$3$7>", RegexOptions.IgnoreCase); |
