diff options
author | Jon Purdy <evincarofautumn@gmail.com> | 2017-10-03 02:51:24 +0300 |
---|---|---|
committer | Jon Purdy <evincarofautumn@gmail.com> | 2017-10-24 20:37:29 +0300 |
commit | e57d26ebaf83d59a6841f6a228990467e8f7f77c (patch) | |
tree | c79b69a96ccd8dce8686bc9424704c04819dca19 /mcs | |
parent | 794f17ef8b3afd5d9744e31bf91c9ea81adf6669 (diff) |
[coop-handles] System.IO.MonoIO.GetFileStat
Diffstat (limited to 'mcs')
-rw-r--r-- | mcs/class/corlib/System.IO/MonoIO.cs | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/mcs/class/corlib/System.IO/MonoIO.cs b/mcs/class/corlib/System.IO/MonoIO.cs index 95589cf19d4..6adabd86f08 100644 --- a/mcs/class/corlib/System.IO/MonoIO.cs +++ b/mcs/class/corlib/System.IO/MonoIO.cs @@ -333,9 +333,20 @@ namespace System.IO } [MethodImplAttribute (MethodImplOptions.InternalCall)] - public extern static bool GetFileStat (string path, - out MonoIOStat stat, - out MonoIOError error); + private unsafe extern static bool GetFileStat (char* path, + out MonoIOStat stat, + out MonoIOError error); + + public static bool GetFileStat (string path, + out MonoIOStat stat, + out MonoIOError error) + { + unsafe { + fixed (char* pathChars = path) { + return GetFileStat (pathChars, out stat, out error); + } + } + } // handle methods |