mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Remove Platform.SupportsReparsePoints query
This commit is contained in:
@@ -217,12 +217,6 @@ namespace System.Management.Automation
|
||||
|
||||
}
|
||||
|
||||
// non-windows does not have reparse points
|
||||
internal static bool SupportsReparsePoints()
|
||||
{
|
||||
return IsWindows;
|
||||
}
|
||||
|
||||
// non-windows does not support removing drives
|
||||
internal static bool SupportsRemoveDrive()
|
||||
{
|
||||
|
||||
@@ -8589,14 +8589,11 @@ namespace Microsoft.PowerShell.Commands
|
||||
|
||||
private static SafeFileHandle OpenReparsePoint(string reparsePoint, FileDesiredAccess accessMode)
|
||||
{
|
||||
if (Platform.SupportsReparsePoints())
|
||||
{
|
||||
return WinOpenReparsePoint(reparsePoint,accessMode);
|
||||
}
|
||||
else
|
||||
{
|
||||
throw new PlatformNotSupportedException();
|
||||
}
|
||||
#if LINUX
|
||||
throw new PlatformNotSupportedException();
|
||||
#else
|
||||
return WinOpenReparsePoint(reparsePoint,accessMode);
|
||||
#endif
|
||||
}
|
||||
|
||||
private static SafeFileHandle WinOpenReparsePoint(string reparsePoint, FileDesiredAccess accessMode)
|
||||
|
||||
Reference in New Issue
Block a user