From ff994d594a815f284102a3bdae128b822f600ffe Mon Sep 17 00:00:00 2001 From: Taloth Saldono Date: Sat, 9 Feb 2019 20:46:39 +0100 Subject: [PATCH] Fixed error in unicode cleanup code removing most non-latin characters instead of just invalid ones. --- src/NzbDrone.Core/Indexers/XmlCleaner.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/NzbDrone.Core/Indexers/XmlCleaner.cs b/src/NzbDrone.Core/Indexers/XmlCleaner.cs index 49a462eec..91d0ea3b1 100644 --- a/src/NzbDrone.Core/Indexers/XmlCleaner.cs +++ b/src/NzbDrone.Core/Indexers/XmlCleaner.cs @@ -8,7 +8,7 @@ public static class XmlCleaner { private static readonly Regex ReplaceEntitiesRegex = new Regex("&[a-z]+;", RegexOptions.Compiled | RegexOptions.IgnoreCase); - private static readonly Regex ReplaceUnicodeRegex = new Regex(@"[^\x09\x0A\x0D\x20-\xD7FF\xE000-\xFFFD\x10000-x10FFFF]", RegexOptions.Compiled | RegexOptions.IgnoreCase); + private static readonly Regex ReplaceUnicodeRegex = new Regex(@"[^\x09\x0A\x0D\u0020-\uD7FF\uE000-\uFFFD]", RegexOptions.Compiled | RegexOptions.IgnoreCase); public static string ReplaceEntities(string content) {