mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-17 12:45:47 +00:00
Remove Platform.SupportsReparsePoints query
This commit is contained in:
1 parent
465e55d32a
commit
dbe16ca5d7
2 files changed
+5
-14
No files matched your search
@@ -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