Browse Source

fix external subtitles with brackets in the filename (#748)

pull/749/head
Jason Dove 4 years ago committed by GitHub
parent
commit
cc9c2f6ae3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      ErsatzTV.FFmpeg/Filter/SubtitlesFilter.cs

5
ErsatzTV.FFmpeg/Filter/SubtitlesFilter.cs

@ -31,6 +31,11 @@ public class SubtitlesFilter : BaseFilter @@ -31,6 +31,11 @@ public class SubtitlesFilter : BaseFilter
.Replace(@":/", @"\\:/");
}
// escape brackets after escaping for windows
effectiveFile = effectiveFile
.Replace(@"[", @"\[")
.Replace(@"]", @"\]");
return $"subtitles={effectiveFile}:fontsdir={fontsDir}";
}
}

Loading…
Cancel
Save