RunProcessAsTask
RunProcessAsTask copied to clipboard
Three minor issues
Hello,
I found three messages in Visual Studio saying following:
1) IDE0067 - Disposable object created by 'new Process {' is never disposed
in ProcessEx.cs
var process = new Process {
2) CA1031 - Modify 'RunAsync' to catch a more specific exception type, or rethrow the exception.
in ProcessEx.cs
} catch (InvalidOperationException) { }
3) CA1031 - Modify 'RunAsync' to catch a more specific exception type, or rethrow the exception.
in ProcessEx.cs
catch (Exception)
{
// best effort to try and get a more accurate start time, but if we fail to access StartTime
// (for instance, process has already existed), we still have a valid value to use.
}
Does it make sense to fix them?
Thanks