Merge pull request #537 from madewokherd/ccwmarshal
[mono.git] / mcs / class / corlib / System.IO / FileInfo.cs
index f03d473956176215fb25577d4f81f79dda57a819..0911f8152c4827f7fdafb5f2dd993d302a651da0 100644 (file)
@@ -49,11 +49,6 @@ namespace System.IO {
        {
                private bool exists;
 
-#if MOONLIGHT
-               internal FileInfo ()
-               {
-               }
-#endif
                public FileInfo (string fileName)
                {
                        if (fileName == null)
@@ -221,6 +216,8 @@ namespace System.IO {
                {
                        MonoIOError error;
 
+                       SecurityManager.EnsureElevatedPermissions (); // this is a no-op outside moonlight
+
                        if (!MonoIO.Exists (FullPath, out error))
                                // a weird MS.NET behaviour
                                return;
@@ -279,12 +276,12 @@ namespace System.IO {
 #if !NET_2_1
                public FileSecurity GetAccessControl ()
                {
-                       throw new NotImplementedException ();
+                       return File.GetAccessControl (FullPath); 
                }
                
                public FileSecurity GetAccessControl (AccessControlSections includeSections)
                {
-                       throw new NotImplementedException ();
+                       return File.GetAccessControl (FullPath, includeSections);
                }
 
                [ComVisible (false)]
@@ -330,7 +327,7 @@ namespace System.IO {
 
                public void SetAccessControl (FileSecurity fileSecurity)
                {
-                       throw new NotImplementedException ();
+                       File.SetAccessControl (FullPath, fileSecurity);
                }
 #endif
        }