Escape the path to pass as a command line argument (#9178)

This commit is contained in:
Dmitry Lyzo
2023-01-28 17:42:58 +03:00
committed by GitHub
parent 0ac18a50f5
commit 09f1c7f535
4 changed files with 8 additions and 5 deletions

View File

@@ -56,7 +56,7 @@ namespace MediaBrowser.MediaEncoding.Encoder
/// </summary>
/// <param name="path">The path.</param>
/// <returns>System.String.</returns>
private static string NormalizePath(string path)
public static string NormalizePath(string path)
{
// Quotes are valid path characters in linux and they need to be escaped here with a leading \
return path.Replace("\"", "\\\"", StringComparison.Ordinal);