FFmpeg.Conversions.FromSnippet.Convert crashes if outputFilePath is just file name.
HubKing opened this issue · comments
static async Task Main(string[] args)
{
Directory.SetCurrentDirectory(AppDomain.CurrentDomain.BaseDirectory);
var snippet = await FFmpeg.Conversions.FromSnippet.Convert("test.mp3", "test.aac");
IConversionResult result = await snippet.Start();
}
System.ArgumentException: 'Path cannot be the empty string or all whitespace. Arg_ParamName_Name'
I looked at the decompiled code and it happened in the code where it tries to creates parent directory, if it does not exist. When the third parameter is just file name, it should just create it in the working directory, instead of crashing.
A workaround is passing "./test.aac" instead of "test.aac".
Fix was deployed with version 5.2.1