ReparsePointAware.RequireSamePath(SafeFileHandle, String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Throws UnauthorizedAccessException if the given SafeFileHandle's canonical path is not the same as expectedPath.
public static void RequireSamePath (Microsoft.Win32.SafeHandles.SafeFileHandle handle, string expectedPath);
static member RequireSamePath : Microsoft.Win32.SafeHandles.SafeFileHandle * string -> unit
Public Shared Sub RequireSamePath (handle As SafeFileHandle, expectedPath As String)
Parameters
- handle
- SafeFileHandle
SafeHandle to the file to check.
- expectedPath
- String
Path to check the handle against.
Exceptions
The path contains Windows Reparse Points or otherwise cannot be accessed.