mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-01-15 23:58:57 +00:00
Address review comments from Bond
This commit is contained in:
@@ -282,12 +282,18 @@ namespace MediaBrowser.MediaEncoding.Encoder
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// With the given path string, replaces the filename with ffprobe, taking case
|
||||
/// of any file extension (like .exe on windows).
|
||||
/// </summary>
|
||||
/// <param name="appPath"></param>
|
||||
/// <returns></returns>
|
||||
private string GetProbePathFromEncoderPath(string appPath)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(appPath))
|
||||
{
|
||||
string pattern = @"[^\/\\]+?(\.[^\/\\\n.]+)?$";
|
||||
string substitution = @"ffprobe$1";
|
||||
const string pattern = @"[^\/\\]+?(\.[^\/\\\n.]+)?$";
|
||||
const string substitution = @"ffprobe$1";
|
||||
|
||||
return Regex.Replace(appPath, pattern, substitution);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user