[jit] Fix the saving of the 'cfg->ret_var_set' flag when inlining, it was set to...
[mono.git] / mcs / class / System.Core / System.IO.Pipes / PipeStream.cs
index fd4a57a693063f4b21c28f755bd953d42089206b..d60b71b1f5b7b29dc18f41994410c17e2e07653a 100644 (file)
@@ -46,9 +46,11 @@ namespace System.IO.Pipes
                // FIXME: not precise.
                internal const int DefaultBufferSize = 0x400;
 
+#if !MOBILE
                internal static bool IsWindows {
                        get { return Win32Marshal.IsWindows; }
                }
+#endif
 
                internal Exception ThrowACLException ()
                {
@@ -131,10 +133,13 @@ namespace System.IO.Pipes
                        get {
                                if (!IsConnected)
                                        throw new InvalidOperationException ("Pipe is not connected");
-                               if (stream == null)
+                               if (stream == null) {
+#pragma warning disable 618
                                        stream = new FileStream (handle.DangerousGetHandle (),
                                                                 CanRead ? (CanWrite ? FileAccess.ReadWrite : FileAccess.Read)
                                                                         : FileAccess.Write, true, buffer_size, IsAsync);
+#pragma warning restore 618                                    
+                               }
                                return stream;
                        }
                        set { stream = value; }
@@ -236,18 +241,26 @@ namespace System.IO.Pipes
 
                public PipeSecurity GetAccessControl ()
                {
+#if MOBILE
+                       throw new PlatformNotSupportedException ();
+#else
                        return new PipeSecurity (SafePipeHandle,
                                                 AccessControlSections.Owner |
                                                 AccessControlSections.Group |
                                                 AccessControlSections.Access);
+#endif
                }
 
                public void SetAccessControl (PipeSecurity pipeSecurity)
                {
+#if MOBILE
+                       throw new PlatformNotSupportedException ();
+#else
                        if (pipeSecurity == null)
                                throw new ArgumentNullException ("pipeSecurity");
                                
                        pipeSecurity.Persist (SafePipeHandle);
+#endif
                }
 
                // pipe I/O