diff --git a/src/dotnet/FileSystem.cs b/src/dotnet/FileSystem.cs index 0208405c..bf829a89 100644 --- a/src/dotnet/FileSystem.cs +++ b/src/dotnet/FileSystem.cs @@ -185,7 +185,8 @@ namespace Fsp } public String MountPoint() { - return IntPtr.Zero != _FileSystem ? Api.FspFileSystemMountPoint(_FileSystem) : null; + return IntPtr.Zero != _FileSystem ? + Marshal.PtrToStringUni(Api.FspFileSystemMountPoint(_FileSystem)) : null; } public IntPtr FileSystemHandle() { diff --git a/src/dotnet/Interop.cs b/src/dotnet/Interop.cs index e9096b65..e0928732 100644 --- a/src/dotnet/Interop.cs +++ b/src/dotnet/Interop.cs @@ -441,8 +441,7 @@ namespace Fsp.Interop internal delegate Int32 FspFileSystemStopDispatcher( IntPtr FileSystem); [UnmanagedFunctionPointer(CallingConvention.Cdecl)] - [return: MarshalAs(UnmanagedType.LPWStr)] - internal delegate String FspFileSystemMountPointF( + internal delegate IntPtr FspFileSystemMountPointF( IntPtr FileSystem); [UnmanagedFunctionPointer(CallingConvention.Cdecl)] internal delegate void FspFileSystemSetOperationGuardStrategyF(