Open peteraritchie opened 1 year ago
In Directory.CreateDirectory, a directory may exist but may not be visible to the current user and incorrectly get flagged for creation. While creating that subdir in this scenario, we should check for an error and not let it leak out if the directory exists. See also https://github.com/dotnet/runtime/blob/main/src/libraries/Common/src/System/IO/FileSystem.DirectoryCreation.Windows.cs#L78
Directory.CreateDirectory
In
Directory.CreateDirectory
, a directory may exist but may not be visible to the current user and incorrectly get flagged for creation. While creating that subdir in this scenario, we should check for an error and not let it leak out if the directory exists. See also https://github.com/dotnet/runtime/blob/main/src/libraries/Common/src/System/IO/FileSystem.DirectoryCreation.Windows.cs#L78